Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
js_support
Contributor
Contributor

java.sql.SQLSyntaxErrorException: ORA-00936: missing expression using tELTOracleOutput

Hello, 

 

I am trying to set up a basic Oracle ELT job with a MERGE "Action on data" for update/insert. The specific error when I run my ELT job is "Exception in component tELTOracleOutput_1 (D_Lead_Inc_ELT) java.sql.SQLSyntaxErrorException: ORA-00936: missing expression"

Attached is my job. Any pointers here are greatly appreciated.

 

Doug

Labels (3)
1 Reply
vapukov
Master II
Master II

in Your original Job design - You are not define keys for Output table (on picture - modified, right LEAD_ID was missed):

0683p000009LynD.png

 

in this case Talend generate construction like:

				String mergeQuery = "MERGE INTO "
						+ tableName_tELTOracleOutput_1 + " target" + " USING ("
						+ select_query_tELTOracleOutput_1 + ") source ON (" +

						"" + ")";

				mergeQuery += " WHEN MATCHED THEN UPDATE SET target.LEAD_TYPE=source.LEAD_TYPE, SKIPPED for make it shorter ";

				mergeQuery += "WHERE " + "source.lead_id = target.lead_id";

this construction - illegal

 

when You define Key for source and target, it would be:

				String mergeQuery = "MERGE INTO "
						+ tableName_tELTOracleOutput_1 + " target" + " USING ("
						+ select_query_tELTOracleOutput_1 + ") source ON (" +

						"target.LEAD_ID=source.LEAD_ID" + ")";

				mergeQuery += " WHEN MATCHED THEN UPDATE SET target.LEAD_TYPE=source.LEAD_TYPE,SKIPPED ";

				mergeQuery += "WHERE " + "source.lead_id = target.lead_id";