Four Stars

Insert data into sybase DB ?

Hi,

 

I am trying to insert data into sybase DB using a file, I am getting the below error. Can you please help me with this

 

Exception in component tSybaseOutput_1 (testing_SPIN_Server)
java.lang.NullPointerException
at com.sybase.jdbc3.jdbc.SybBCP.<init>(Unknown Source)
at com.sybase.jdbc3.jdbc.SybPreparedStatement.a(Unknown Source)
at com.sybase.jdbc3.jdbc.SybPreparedStatement.<init>(Unknown Source)
at com.sybase.jdbc3.jdbc.SybConnection.a(Unknown Source)
at com.sybase.jdbc3.jdbc.SybConnection.prepareStatement(Unknown Source)
at com.sybase.jdbc3.jdbc.SybConnection.prepareStatement(Unknown Source)
at local_project.testing_spin_server_0_1.testing_SPIN_Server.tFileInputDelimited_1Process(testing_SPIN_Server.java:817)
at local_project.testing_spin_server_0_1.testing_SPIN_Server.runJobInTOS(testing_SPIN_Server.java:1601)
at local_project.testing_spin_server_0_1.testing_SPIN_Server.main(testing_SPIN_Server.java:1390)

 

Thanks & Regards

Akshay

6 REPLIES
Moderator

Re: Insert data into sybase DB ?

Hello,

Did you use tSybaseConnection component in your job design? Could you please post your work flow screenshot into forum which will be helpful for us to address your issue.

Best regards

Sabrina

--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
Moderator

Re: Insert data into sybase DB ?

Hello,

Feel free to let us know if there is any problem for you to upload screenshots into forum.

Best regards

Sabrina

--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
Four Stars

Re: Insert data into sybase DB ?

Hi Sabrina,

 

I have attached file with screenshot. I have added tsybaseconnection now. my job is like below

tsybaseconnection ----->onSubjobOK--->tfileinputdelimited--->tmap---->tsybaseoutput.

I am just trying to insert one single record with 2 values. 

 

The connection details are correct.

 

Thanks & Regards

Akshay

Four Stars

Re: Insert data into sybase DB ?

Hi Sabrina,

 

The issue is with tsybaseoutput component, if I use tlogrow instead of tsybaseoutput I am able to see the output on screen . 

I tried to run a insert query manually and it works so no issue with the DB. 

 

Thanks & Regards

Akshay

Moderator

Re: Insert data into sybase DB ?

Hi,

Would you mind posting your tsybaseoutput component setting screenshot into forum? Please mask your sensitive data.

In addition, have you tried to check out "Die on error" option on basic settings of tsybaseoutput component to see if there is any error message printed on console?

Best regards

Sabrina

--
Don't forget to give kudos when a reply is helpful and click Accept the solution when you think you're good with it.
Four Stars

Re: Insert data into sybase DB ?

Hi Sabrina,

 

This issue is solved, it was a small datatype issue from end . Can you please guide me as to how can we update or insert using tsybasebulkexec component. I see there is either update or insert option only . I want the records to be updated if it is already present in the database else it should be inserted if not present.

 

Thanks & Regards

Akshay