You are using the ABAP class 'cl_shdb_seltab' for converting selection tables into SQL WHERE clause.
When you execute your program, it fails with a short dump like the following:
Category ABAP programming error
Runtime Errors SAPSQL_PARSE_ERROR
ABAP Program XXXXXX
Application Component Not assigned
An error has occurred while parsing a dynamic entry.
An exception has occurred which is explained in more detail below. The
exception, which is assigned to class 'CX_SY_DYNAMIC_OSQL_SYNTAX' was not
caught and therefore caused a runtime error. The reason for the exception is:
The current ABAP program attempted to execute an Open SQL statement
containing a dynamic entry. The parser returned the following error:
""AND" is not valid here."
The part of the code which fails is similar to the following:
24 DATA(lv_where) = cl_shdb_seltab=>combine_seltabs(
25 it_named_seltabs = VALUE #(
26 ( name = 'VBELN' dref = REF #( vbeln ) )
27 ( name = 'AUART' dref = REF #( auart ) ) ) ).
>>>>> select single * from vbak into wa_vbak
30 where (lv_where).
- SAP Systems based on SAP NetWeaver;
- SAP HANA Database;
AMDP, SELTAB, ABAP, SQL-WHERE, CX_SY_DYNAMIC_OSQL_SYNTAX, DUMP, SAPSQL_PARSE_ERROR , KBA , BC-DB-HDB-POR , Dictionary & Consistency checks for SAP HANA , HAN-DB , SAP HANA Database , BC-ABA , ABAP Runtime Environment - ABAP Language Issues Only , Problem
About this pageThis is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP ONE Support launchpad (Login required).
Search for additional results
Visit SAP Support Portal's SAP Notes and KBA Search.