Variable into Query

39 views
Skip to first unread message

ab_db

unread,
Feb 12, 2014, 10:19:57 AM2/12/14
to db...@googlegroups.com
Hi All,
I am trying to pass a variable into the Query   by using the << variable which is throwing a exception 

java.sql.SQLSyntaxErrorException: ORA-00936: missing expression
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:447)
	at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:396) 
at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:951) ........


DBfit code

DatabaseEnvironmentORACLE
ConnectUsingFile.\Connections\ClassDW.config

Given a customer record in the CLASS_DW

QuerySELECT REFERENCE FROM CUSTOMERS WHERE rownum = 1
REFERENCE?
>> custrec = 80129979752

and the customer does not exist in the integration layer
DatabaseEnvironmentORACLE
ConnectUsingFile.\Connections\Integration.config

QuerySELECT distinct 0 as CUSTOMER_ID from H_CUSTOMERS where CUSTOMER_ID <> << custrec
CUSTOMER_ID?
0  

Any help is appreciated?

Many Thanks,

ab_db

unread,
Feb 13, 2014, 4:32:14 AM2/13/14
to db...@googlegroups.com
Sorry got the answer for the variable in ORACLE use : not << to read the variable. :custrec worked. Cheers
Reply all
Reply to author
Forward
0 new messages