cancel
Showing results for 
Search instead for 
Did you mean: 

Stored Procedure in PI

Former Member
0 Kudos

Hi All,

The scenario is Soap to JDBC.

In JDBC we are executing an stored procedure. Based on the input , the stored procedure returns an value.

If the input doesnot exist in the database, then stored procedure returns an NULL value.

Whenever the null value is returned by Stored procedure.we are getting the following error.

<SAP:AdditionalText>com.sap.engine.interfaces.messaging.api.exception.MessagingException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'bgs_slsc1301_pkge.sp_get_prdhld' (structure 'Statement'): java.lang.NullPointerException:</

kindly help me in how to resolve this error.

thanks in advance.

suja

Accepted Solutions (0)

Answers (3)

Answers (3)

rajasekhar_reddy14
Active Contributor
0 Kudos

This is because of Payload fromat exception,try to chnage the logic .Instead of returning null use empty or blank.i hpe it will work out.

Former Member
0 Kudos

Hi Sujatha,

can you check below two blogs, i hope they are of some help!

/people/bhavesh.kantilal/blog/2006/07/03/jdbc-receiver-adapter--synchronous-select-150-step-by-step JDBC Receiver Adapter -- Synchronous Select u2013 Step by Step

/people/sap.user72/blog/2005/10/15/jdbc-adapter-execution-mode-chained-or-unchained JDBC Adapter execution mode Chained or Unchained ??

Regards,

Jilan

VijayKonam
Active Contributor
0 Kudos

Changing the SP to return an empty record set instead of a NULL is the only solution here.

VJ

former_member187339
Active Contributor
0 Kudos

Hi Sujatha,

>>If the input doesnot exist in the database, then stored procedure returns an NULL value.

I will suggest to change the SP such that it returns BLANK node intsean of NULL.

Also see the occurrence of the node if the min Occur is 0 then it shoudl bnot be a problem.

Can you paste the input and output of SP here?

Regards

Suraj