tContextLoad - How to load null values

One Star

tContextLoad - How to load null values

Hello,
I would like to use tContextLoad to load a delimited file key;value
How can I do to load null values... If I don't put any value (even no space) then a value is automatically set (empty string).... which is not the same as NULL.
tContextLoad_2 set key "JDBC_Wallet_ClassName" with value "oracle.jdbc.OracleDriver"
tContextLoad_2 set key "JDBC_Wallet_DriverJar" with value "D:\ECB\Talend\TOS_DI-r101800-V5.3.0\lib\java\ojdbc6.jar"
tContextLoad_2 set key "JDBC_Wallet_JdbcUrl" with value "jdbcSmiley Surprisedracle:thin:/@GPDVL_SQL_PCU_A142762"
tContextLoad_2 set key "JDBC_Wallet_Login" with value ""
tContextLoad_2 set key "JDBC_Wallet_MappingFile" with value "oracle_id"
tContextLoad_2 set key "JDBC_Wallet_Password" with value ""
Thanks for your support,
François,
Community Manager

Re: tContextLoad - How to load null values

Hi
Set the default value of JDBC_Wallet_Login and JDBC_Wallet_Password as null, and don't load the variables that need to be null from text file.
Shong
----------------------------------------------------------
Talend | Data Agility for Modern Business
One Star

Re: tContextLoad - How to load null values

Hello,
I tried your suggestion... but no success... (see job log below... and "test" job design in attachement)
I don't understand...
Do you have other suggestions ?
Thanks,
François,
Starting job TestWallet at 09:35 21/06/2013.

connecting to socket on port 3407
connected
2013-06-21 09:35:52|Fz82Vn|Fz82Vn|Fz82Vn|5816|GAF|TestWallet|_QdjccNdGEeK-cP9tHeVS9Q|0.1|Default||begin||
I2P_GAF_2013022614450000.XML
I2P_GAF_2013040223210101.XML
I2P_GAF_2012062800020101.XML
tContextLoad_2 set key "JDBC_Wallet_ClassName" with value "oracle.jdbc.OracleDriver"
tContextLoad_2 set key "JDBC_Wallet_DriverJar" with value "D:\ECB\Talend\TOS_DI-r101800-V5.3.0\lib\java\ojdbc6.jar"
tContextLoad_2 set key "JDBC_Wallet_JdbcUrl" with value "jdbcSmiley Surprisedracle:thin:/@GPDVL_SQL_PCU_A142762"
tContextLoad_2 set key "JDBC_Wallet_MappingFile" with value "oracle_id"
JDBC_Wallet_MappingFile|oracle_id
JDBC_Wallet_Password|null
JDBC_Wallet_ClassName|oracle.jdbc.OracleDriver
JDBC_Wallet_Login|null
JDBC_Wallet_DriverJar|D:\ECB\Talend\TOS_DI-r101800-V5.3.0\lib\java\ojdbc6.jar
Wallet_entry|jdbcSmiley Surprisedracle:thin:/@GPDVL_SQL_PCU_A142762
JDBC_Wallet_JdbcUrl|jdbcSmiley Surprisedracle:thin:/@GPDVL_SQL_PCU_A142762
Exception in component tJDBCConnection_2
java.sql.SQLException: ORA-01017: invalid username/password; logon denied
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:389)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:382)
at oracle.jdbc.driver.T4CTTIfun.processError(T4CTTIfun.java:600)
at oracle.jdbc.driver.T4CTTIoauthenticate.processError(T4CTTIoauthenticate.java:445)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:380)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:760)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:401)
at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:546)
at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:236)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:521)
at java.sql.DriverManager.getConnection(Unknown Source)
at java.sql.DriverManager.getConnection(Unknown Source)
at gaf.testwallet_0_1.TestWallet.tJDBCConnection_2Process(TestWallet.java:2519)
at gaf.testwallet_0_1.TestWallet.tFileInputDelimited_1Process(TestWallet.java:2117)
at gaf.testwallet_0_1.TestWallet.tJDBCInput_1Process(TestWallet.java:1637)
at gaf.testwallet_0_1.TestWallet.tJDBCConnection_1Process(TestWallet.java:653)
at gaf.testwallet_0_1.TestWallet.runJobInTOS(TestWallet.java:4764)
at gaf.testwallet_0_1.TestWallet.main(TestWallet.java:4590)
Caused by: java.sql.SQLException: ORA-01017: invalid username/password; logon denied
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:445)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:389)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:382)
at oracle.jdbc.driver.T4CTTIoauthenticate.processError(T4CTTIoauthenticate.java:441)
at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:450)
at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
at oracle.jdbc.driver.T4CTTIoauthenticate.doOSESSKEY(T4CTTIoauthenticate.java:404)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:385)
... 12 more
2013-06-21 09:35:53|Fz82Vn|Fz82Vn|Fz82Vn|GAF|TestWallet|Default|6|Java Exception|tJDBCConnection_2|java.sql.SQLExceptionSmiley SurprisedRA-01017: invalid username/password; logon denied
|1
2013-06-21 09:35:53|Fz82Vn|Fz82Vn|Fz82Vn|5816|GAF|TestWallet|_QdjccNdGEeK-cP9tHeVS9Q|0.1|Default||end|failure|1071
disconnected
Job TestWallet ended at 09:35 21/06/2013.
Seventeen Stars

Re: tContextLoad - How to load null values

hi all,
I don't understand why you want null value as login & password
=> java.sql.SQLException: ORA-01017: invalid username/password; logon denied
it's a normal behavior , isn't it ?
regards
laurent
One Star

Re: tContextLoad - How to load null values

Hello Laurent,
No, it's not a normal behavior... Goal is to use an Oracle Wallet where all credentials are stored... No, the combination of the JDBC URL & System Property oracle.net.wallet_location give the Oracle Wallet entry to use to retrieve credentials. That's the reason I have to put both login & password to NULL.
Regards,
Fr,