Inserting or Updating Xml data into Oracle table
Posted: Mon May 04, 2015 10:20 pm
Hi,
Im trying to read XML data from Oracle XMLType column and insert into another Oracle table column of XMLType using ODBC Connector stage in datastage 8.1.
During insert the below error is thrown:-
ODBC_Connector: ODBC function "SQLFetch" reported: SQLSTATE = HYC00: Native Error Code = 0: Msg = [IBM(DataDirect OEM)][ODBC Oracle driver]Driver does not support selecting a column of type XMLType. You must cast columns of type XMLType to a CLOB by using the cast function.
How to overcome this error?
Query used to read data :-
select x.REPORT_XML.getclobval() as REPORT_XML,CR_RPT_NUM ,PAGE_IND from temp x;
Insert Statement in ODBC Connector:-
INSERT INTO temp1(REPORT_XML,CR_RPT_NUM,PAGE_IND) VALUES(sys.xmltype.createxml(ORCHESTRATE.REPORT_XML),ORCHESTRATE.CR_RPT_NUM,ORCHESTRATE.PAGE_IND)
Im trying to read XML data from Oracle XMLType column and insert into another Oracle table column of XMLType using ODBC Connector stage in datastage 8.1.
During insert the below error is thrown:-
ODBC_Connector: ODBC function "SQLFetch" reported: SQLSTATE = HYC00: Native Error Code = 0: Msg = [IBM(DataDirect OEM)][ODBC Oracle driver]Driver does not support selecting a column of type XMLType. You must cast columns of type XMLType to a CLOB by using the cast function.
How to overcome this error?
Query used to read data :-
select x.REPORT_XML.getclobval() as REPORT_XML,CR_RPT_NUM ,PAGE_IND from temp x;
Insert Statement in ODBC Connector:-
INSERT INTO temp1(REPORT_XML,CR_RPT_NUM,PAGE_IND) VALUES(sys.xmltype.createxml(ORCHESTRATE.REPORT_XML),ORCHESTRATE.CR_RPT_NUM,ORCHESTRATE.PAGE_IND)