[resolved] Oracle advanced settings sql expression

Highlighted
One Star

[resolved] Oracle advanced settings sql expression

Hi,
I'm trying to add a new column in the inputOracleComponent with the following sql expresion:
"to_date(? , 'yyyy-mm-dd')"
I'm getting the next error:
Exception in component tOracleOutput_1
java.sql.SQLException: Missing IN or OUT parameter at index:: 14
at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:70)
at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:131)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:197)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:261)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:269)
at oracle.jdbc.driver.OraclePreparedStatement.processCompletedBindRow(OraclePreparedStatement.java:1738)
at oracle.jdbc.driver.OraclePreparedStatement.addBatch(OraclePreparedStatement.java:9118)
at oracle.jdbc.driver.OraclePreparedStatementWrapper.addBatch(OraclePreparedStatementWrapper.java:1070)
at test.loadlkemployeeexceljob_0_1.LoadLKEmployeeExcelJOB.tFileInputExcel_1Process(LoadLKEmployeeExcelJOB.java:2289)
at test.loadlkemployeeexceljob_0_1.LoadLKEmployeeExcelJOB.runJobInTOS(LoadLKEmployeeExcelJOB.java:2720)

Could you help me please?

Accepted Solutions
Seventeen Stars

Re: [resolved] Oracle advanced settings sql expression

OK the tOracleOutput component uses prepared statement but they are only created and filled by the schema columns. If you add a prepared statement, there is no way in this component to set a value for it.

All Replies
Seventeen Stars

Re: [resolved] Oracle advanced settings sql expression

The tOracleInput component does not support prepared statement parameter. Your sql snippet contains a prepared statement. The only component so far supporting prepared statements is the tOracleRow component. Here you can set the values for the prepared statements in the advanced setting.
One Star

Re: [resolved] Oracle advanced settings sql expression

Jlolling,
sorry i mean the oracle output component, as you can see in the error message.
Seventeen Stars

Re: [resolved] Oracle advanced settings sql expression

OK the tOracleOutput component uses prepared statement but they are only created and filled by the schema columns. If you add a prepared statement, there is no way in this component to set a value for it.

2019 GARNER MAGIC QUADRANT FOR DATA INTEGRATION TOOL

Talend named a Leader.

Get your copy

OPEN STUDIO FOR DATA INTEGRATION

Kickstart your first data integration and ETL projects.

Download now

What’s New for Talend Summer ’19

Watch the recorded webinar!

Watch Now

Best Practices for Using Context Variables with Talend – Part 1

Learn how to do cool things with Context Variables

Blog

Migrate Data from one Database to another with one Job using the Dynamic Schema

Find out how to migrate from one database to another using the Dynamic schema

Blog

Best Practices for Using Context Variables with Talend – Part 4

Pick up some tips and tricks with Context Variables

Blog