Strings with Quotes in Oracle Connector-Stage
Posted: Mon Jan 10, 2011 3:19 am
In a PX-Job using Runtime-Column-Propagation I try to use an SQL-Statement like this:
Select * from #SOURCETAB# #WHERE_COND#
where #SOURCETAB# is the name of the selected table and #WHERE_COND# is an optional Where-Clause which may contain strings in quotation-marks.
When running the job with #WHERE_COND# = WHERE BWKEY = '0022' the job returns:
Oracle_Enterprise_15,0: (aptoci.C:460). Message: ORA-01722: invalid number.
Obviously the quotation-marks are eliminated when running the job.
My guess was, that it may be necessary to mask the quotation-marks whithin the strings, so I tried to double the quotation-marks.
The result, however, is still the same. It looks like DataStage simply removes all quotation-marks from within the parameter-string.
Does anybody know the correct way to pass the parameter-string?
Any suggestions welcome.
Select * from #SOURCETAB# #WHERE_COND#
where #SOURCETAB# is the name of the selected table and #WHERE_COND# is an optional Where-Clause which may contain strings in quotation-marks.
When running the job with #WHERE_COND# = WHERE BWKEY = '0022' the job returns:
Oracle_Enterprise_15,0: (aptoci.C:460). Message: ORA-01722: invalid number.
Obviously the quotation-marks are eliminated when running the job.
My guess was, that it may be necessary to mask the quotation-marks whithin the strings, so I tried to double the quotation-marks.
The result, however, is still the same. It looks like DataStage simply removes all quotation-marks from within the parameter-string.
Does anybody know the correct way to pass the parameter-string?
Any suggestions welcome.