SAP Knowledge Base Article - Public

3055415 - Runtime error "SYNTAX_ERROR" occurs when creating sales quotations or sales orders

Symptom

After the Q system upgraded to CE2105, runtime error "SYNTAX_ERROR" occurs when creating sales orders or sales quotations using all the sales apps (Create Sales Orders / Create Sales Orders - VA01 / Change Sales Orders - VA02 / Display Sales Orders - VA03 / Create Sales Orders / Manage Sales Quotations……).

Environment

SAP S/4HANA CLOUD CE2105

Cause

The dump happens because of a syntax error in the Cloud BAdI implementation "Sales Header Modification". As an example, the logic implemented by the customer in the Cloud BAdI implementation "Sales Header Modification" may look like this:

....

SELECT SINGLE *
FROM I_SalesQuotationPartner
INTO @salespartner
WHERE I_SalesQuotationPartner~SalesQuotation = @salesdocument-salesdocument
AND I_SalesQuotationPartner~PartnerFunction = 'AP'. "Contact person

....

With CE2105, some new standard fields were added to the I_SalesOrderPartner, but not to I_SalesQuotationPartner. As a result of this, now the two structures are not type compatible anymore. When selecting from I_SalesQuotationPartner into a structure of type I_SalesOrderPartner, there will be a syntax error in the custom coding.

Resolution

Currently, please replace the "SELECT SINGLE *" with "Select Single contactperson, personnel" ("contactperson, personnel" act just as an example here). Also, change "INTO @salespartner" to "INTO CORRESPONDING FIELDS OF @salespartner".

Please also contact SAP to help correct the code in your P system manually in the same way before P system upgrade. This is because it is not possible to transport from Q to P System before the P system gets the upgrade. Otherwise, you have to transport changes after P system upgrade and this would lead to dumps in the P System until the transport reaches the P system.

Keywords

Regression, Runtime Error, SYNTAX_ERROR, CE2105, Create Sales Orders, Create Sales Orders - VA01, Change Sales Orders - VA02, Display Sales Orders - VA03, Create Sales Orders, Manage Sales Quotations, Sales Header Modification, I_SalesOrderPartner , KBA , SD-SLS-SO , Sales Orders , Problem

Product

SAP S/4HANA Cloud 2105