Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Exception in component tDBInput_2 (METROSCOPE_V04)
org.talend.components.api.exception.ComponentException: SQL_ERROR:{message=Failed to read from stream}
tContextLoad_1 set key "Emplacement_ini" with value "D:\ScriptMetroscope\Input"
tContextLoad_1 set key "Emplacement_Out" with value "D:\ScriptMetroscope\Output"
tContextLoad_1 set key "Date_Debut" with value "08/09/2022 15:00:00"
tContextLoad_1 set key "Date_Fin" with value "08/09/2022 15:10:00"
tContextLoad_1 set key "STEP" with value "10m"
tContextLoad_1 set key "SRV_PI_NAME" with value "DCEYY2Q2"
Exception in component tDBInput_2 (SCRIPT_METROSCOPE_V04)
org.talend.components.api.exception.ComponentException: SQL_ERROR:{message=Failed to read from stream}
at org.talend.components.jdbc.CommonUtils.newComponentException(CommonUtils.java:572)
at org.talend.components.jdbc.runtime.reader.JDBCInputReader.start(JDBCInputReader.java:213)
at org.talend.codegen.flowvariables.runtime.FlowVariablesReader.start(FlowVariablesReader.java:73)
at local_project.script_metroscope_v04_0_1.SCRIPT_METROSCOPE_V04.tIterateToFlow_1_AIProcess(SCRIPT_METROSCOPE_V04.java:7492)
at local_project.script_metroscope_v04_0_1.SCRIPT_METROSCOPE_V04.tFileList_1Process(SCRIPT_METROSCOPE_V04.java:1846)
at local_project.script_metroscope_v04_0_1.SCRIPT_METROSCOPE_V04.tFileInputDelimited_2Process(SCRIPT_METROSCOPE_V04.java:1233)
at local_project.script_metroscope_v04_0_1.SCRIPT_METROSCOPE_V04.runJobInTOS(SCRIPT_METROSCOPE_V04.java:8850)
at local_project.script_metroscope_v04_0_1.SCRIPT_METROSCOPE_V04.main(SCRIPT_METROSCOPE_V04.java:8654)
Caused by: java.sql.SQLException: Failed to read from stream
at com.osisoft.jdbc.StatementImpl.getQueryReturnType(StatementImpl.java:345)
at com.osisoft.jdbc.StatementImpl.executeQuery(StatementImpl.java:418)
at org.talend.components.jdbc.runtime.reader.JDBCInputReader.start(JDBCInputReader.java:209)
... 6 more
Caused by: com.osisoft.rdsa.RdsaException: Failed to read from stream
at com.osisoft.rdsa.Command.QueryReturnsResultSet(Native Method)
at com.osisoft.rdsa.Command.queryReturnsResultSet(Command.java:93)
at com.osisoft.jdbc.StatementImpl.getQueryReturnType(StatementImpl.java:340)
... 8 more
2022-09-09 12:13:48|Hbs6EB|Hbs6EB|Hbs6EB|LOCAL_PROJECT|SCRIPT_METROSCOPE_V04|Context|6|Java Exception|tDBInput_2|org.talend.components.api.exception.ComponentException:SQL_ERROR:{message=Failed to read from stream}|1
If any one have on idea for this problem...
Thanks , BR
Hello,
Could you please try pass your PI_tag in Context value and use it in query instead of global variable?
The job design looks like:
Input-->tflowtoiterate-->tjavarow(context.PI_tag)
|
OnsubjobOk
tDBInput-->tfileoutputXXX
Any the Dynamic query a use in the tDBInput
"SELECT time,value,tag from piarchive..piavg WHERE tag IN "+context.PI_tag+"' AND time between '"+context.Date_Debut+"' AND '"+context.Date_Fin+"'
Feel free to let us know if it is OK with you.
Best regards
Sabrina
Here is a Dynamic query a use in the tDBInput
"SELECT time,value,tag from piarchive..piavg WHERE tag IN "+((String)globalMap.get("out1.PI_tag"))+" AND time between '"+context.Date_Debut+"' AND '"+context.Date_Fin+"'"
When I change the term "((String)globalMap.get("out1.PI_tag"))" with a string it's work...
Hello,
Could you please try pass your PI_tag in Context value and use it in query instead of global variable?
The job design looks like:
Input-->tflowtoiterate-->tjavarow(context.PI_tag)
|
OnsubjobOk
tDBInput-->tfileoutputXXX
Any the Dynamic query a use in the tDBInput
"SELECT time,value,tag from piarchive..piavg WHERE tag IN "+context.PI_tag+"' AND time between '"+context.Date_Debut+"' AND '"+context.Date_Fin+"'
Feel free to let us know if it is OK with you.
Best regards
Sabrina