cancel
Showing results for 
Search instead for 
Did you mean: 

"ORA-00933: SQL command not properly ended" problem

Former Member
0 Kudos

Hello,

I have scenario from RFC to Oracle database.

When I tried to run this scenario I received the error.

My statement is:

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

- <ns1:ecc_material_MT xmlns:ns1="com:netafim:pricing:ecc_material">

- <STATEMENTNAME>

- <PRICING_MATERIAL_MASTER action="UPDATE_INSERT">

<TABLE>PRICING_MATERIAL_MASTER</TABLE>

- <access>

<MATNR>000000092420001000</MATNR>

<MATDESC>3XLLDB005350 TALC NA FOR HI-KAFRIT</MATDESC>

<MG>70-008</MG>

<MGDESC>RM RESIN MB INJ</MGDESC>

<PG>92420</PG>

<PGDESC>TALC MB</PGDESC>

<STATUS />

<DELETION_DATE hasQuot="No">TO_DATE('0000-00-00', 'YYYY-MM-DD')</DELETION_DATE>

</access>

- <key>

<MATNR>000000092420001000</MATNR>

</key>

</PRICING_MATERIAL_MASTER>

</STATEMENTNAME>

</ns1:ecc_material_MT>

When I unmapped the fields" MATDESC, MGDESC, DELETION_DATE the scenario work OK.

My questions are:

Way this problem happened?

Where I can find in the XI information about the expect problem?

Thank you

Elad

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi

Better put

Receiver Adapter (JDBC) Additional parameters

Parameter name: "logSQLStatement"
Parameter type: true

in RWB --> in Aduit log u will get the

SQL statement , check running it in SQL of u r ORACLE DB.

u will get the trace of u r error

regards

Srini

Former Member
0 Kudos

Hello Srini,

I'm not understand your answer.

You can explain it?

Elad

Former Member
0 Kudos

ok in JDBC Receiver Coomuincation channel Configuration

u will have "Additional Parameters"

Right side colum give --> logSQLStatement (refer above)

Left side column give --> true

Save u r Config --> Activate

  • Now run u r scenario again

Now goto Runtime work bench --> RWB --> Comunication channel --> Receiver JDBC Adapter (Click on it)

-


> Now u will see (aduit log) --> read it complete --> at some poiont u will get > SQL statement genareted by Rec jdbc>

Copy the SQL Statement --> run it in u r local Client of ORACLE (SQL plus) it will give u error --> ask u r DB person to reason and go back to XI for mapping changes if need , also check u r interface structure.

rgds

srini

Former Member
0 Kudos

Hello srini,

I did what you recomend me and I'm not found any audit log.

Elad

Former Member
0 Kudos

go to RWB -- > message monitoring -- > select that message and click detail , you will see the audit log , where you can find sql statement as said above.

Former Member
0 Kudos

Hi

When u click on Adapter --> in RWB u will get the Aduit log ,

it will be almost last so --> click next page (down arrow button) to get next page of aduit log

u will find sql statement

rgds

srini

Former Member
0 Kudos

Hello,

This is all the errors from the AuditLog

08.07.2009 07:58:18 Error Unable to execute statement for table or stored procedure. 'PRICING_MATERIAL_MASTER' (Structure 'STATEMENTNAME') due to java.sql.SQLException: ORA-00933: SQL command not properly ended

08.07.2009 07:58:18 Error 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. 'PRICING_MATERIAL_MASTER' (structure 'STATEMENTNAME'): java.sql.SQLException: ORA-00933: SQL command not properly ended

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

08.07.2009 07:58:18 Error 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. 'PRICING_MATERIAL_MASTER' (structure 'STATEMENTNAME'): java.sql.SQLException: ORA-00933: SQL command not properly ended.

But how can this errors can halp me to solve this issue?

Elad

Former Member
0 Kudos

Hi

have u given the parameters in u r receiver jdbc adapter

in rwb -- after clicking the link , u goto the next page of the aduit log u will find for sure

refer sapnote : 801367

rgds

srini

Former Member
0 Kudos

Hi

For your reference

in Aduit tab u can see log as below (Taken from our PI Box)

Audit Log for Message: 4a48f267-604a-0098-e100-80000a0a093e 
 
Time Stamp Status Description 
2009-06-30 14:20:21 Success INSERT INTO  SAP_XXXXT (DATE_CREATED, MX_TIMESTAMP, TABLE_NAME, KEY_VALUE, MESSAGE_NUM, MESSAGE_TEXT) VALUES (2009/06/30, 14:20:20, SAP_EEEE, S, 000, Article ID Sucessfully Inserted / Updated) 
2009-06-30 14:20:21 Success DB_TEST
2009-06-30 14:20:21 Success Database request processed successfully 
2009-06-30 14:20:21 Success MP: Leaving module processor 
2009-06-30 14:20:21 Success The message status set to DLVD. 
2009-06-30 14:20:21 Success The message was successfully delivered to the application using connection JDBC_http://sap.com/xi/XI/System.

can u see "INSERT INTO " statement with sucess , u will also get UPDATE_INSERT if u have mainted the paramaters in CC JBDC

rgds

srini

Answers (2)

Answers (2)

Former Member
0 Kudos

When I unmapped the fields" MATDESC, MGDESC, DELETION_DATE the scenario work OK.

Can you just unmap each one of them one each time and check which field is causing the error..

There might be some incompatibility with the format.

Former Member
0 Kudos

Ok now I can see the statement,

When I try to use with INSERT statement or with UPDATE_INSERT statment

INSERT INTO PRICING_MATERIAL_MASTER (MATNR, MATDESC, MG, PG, STATUS) VALUES ('000000092420001000', '3XLLDB005350 TALC NA FOR HI-KAFRIT', 70-008, 92420, NULL)

I received the error:

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. 'PRICING_MATERIAL_MASTER' (structure 'STATEMENTNAME'): java.sql.SQLException: ORA-00917: missing comma

Elad

Former Member
0 Kudos

Hello,

Now, after I added the line to CC I can see the statment in RWB.

Elad

Former Member
0 Kudos

hi,

Ensure some basic checks.

Check in the DB that how many bytes are allocated for those fields?

Are you providing the right date format in for deletedate column?

use the message monitoring option to find where exactly

To check the adapter you can check from here.

RWB-Component MonitoringAdapter Engine--Adapter Monitoring

Go for the message monitoring to find out the exact cause

Kishore