cancel
Showing results for 
Search instead for 
Did you mean: 

JDBC Receiver Adapter

Former Member
0 Kudos

Hello,

I have following synch. scenario.

Proxy -


XI -


JDBC (Oracle)

In this scenario JDBC is receiver adpater.

Also I used some UDF to create dynamic SQL everytime a message is processed. I have turned on debugging SQL statement on receiver adapater.

When I tested scenario, the SQL statement looks like as follows.

SELECT customer_id, cust_name, addr1, city, state_cd, zip, country_cd, long_name FROM SYSADM.CUSTOMER_MASTER_TBL WHERE customer_id='422628'

I get following error. I ran the above SQL statment in the SQLPLUS tool and got results back. Now my question is why am I getting error? How to resolve it. I appreciate your help.

Unable to execute statement for table or stored procedure. 'SearchElements' (Structure 'Statement') due to java.sql.SQLException: ORA-00933: SQL command not properly ended

MP: exception caught with cause com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'SearchElements' (structure 'Statement'): java.sql.SQLException: ORA-00933: SQL command not properly ended

Exception caught by adapter framework: Error processing request in sax parser: Error when executing statement for table/stored proc. 'SearchElements' (structure 'Statement'): java.sql.SQLException: ORA-00933: SQL command not properly ended

Delivery of the message to the application using connection JDBC_http://sap.com/xi/XI/System failed, due to: com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'SearchElements' (structure 'Statement'): java.sql.SQLException: ORA-00933: SQL command not properly ended . Setting message to status failed.

Returning synchronous error message to calling application: com.sap.aii.af.ra.ms.api.RecoverableException: Error processing request in sax parser: Error when executing statement for table/stored proc. 'SearchElements' (structure 'Statement'): java.sql.SQLException: ORA-00933: SQL command not properly ended .

Thank you,

Balaji

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

Check your target structure and still if it is not clear , go to RWB, Comunication channel monitoring, your jdbc channel. Pick your target data payload from receiver adapter and paste it here. I'll try to tell you what's wrong in the structure.

thanks

amit

Former Member
0 Kudos

Amit,

Thank you for the response, the following is message structure.

<?xml version="1.0" encoding="UTF-8" ?>

- <ns0:MT_Cma_Customer_Search_Request xmlns:ns0="urn:http://freemanco.com/xi/cma_customer_search">

- <Statement>

- <SearchElements action="SQL_QUERY">

<access>SELECT customer_id, cust_name, addr1, city, state_cd, zip, country_cd, long_name FROM SYSADM.CUSTOMER_MASTER_TBL WHERE customer_id=''722628''</access>

</SearchElements>

</Statement>

</ns0:MT_Cma_Customer_Search_Request>

Please let me know.

Thank you,

Balaji

Former Member
0 Kudos

Hi,

It looks like you are using double quotes in where clause value of customer_id


SELECT customer_id, cust_name, addr1, city, state_cd, zip, country_cd, long_name FROM SYSADM.CUSTOMER_MASTER_TBL WHERE customer_id=''722628''


SELECT customer_id, cust_name, addr1, city, state_cd, zip, country_cd, long_name FROM SYSADM.CUSTOMER_MASTER_TBL WHERE customer_id='722628'

give the value of customer_id value in single quotes and try.

thanks

amit

Former Member
0 Kudos

It worked.

Thank you,

Balaji

Answers (1)

Answers (1)

agasthuri_doss
Active Contributor
0 Kudos