cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping Lookup from ABAP stack issue in SAP PO

Former Member
0 Kudos

Hi PI Folks,

Need your help , we are upgrading from PI 7.0 to PI 7.4 Version

Initially a mapping lookup was being done in SAP PI wherein
the tables were maintained in PI ABAP stack sitting on SQL server. A JDBC
channel was configured for the same and the SQL statement/s were used during
runtime for fetching data.

 

Now since we are moving to single stack 7.4 we tried to
replicate the same functionality with the ABAP tables now being placed in ECC.
ECC sits on AS400 and when the similar command is executed we run into error/s.
Tried both the protocols ‘Native SQL String’ & ‘XML SQL Format’ but the
error remains same.

( Attached Error)

Appreciate some input on this. Thanks

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Rohit

Normally we use RFC adapter for look up in ECC tables. I am just curious to know why you are using JDBC to connect to SAP system.

Are you not able to connect to ECC from PI using RFC adapter ?

Former Member
0 Kudos

Well this is a migration project. The AS-IS architecture made use of this JDBC adapter. MappingLookup API was used and in the UDFs the table names along with key/required values were passed at runtime. SInce the number of UDFs is close to 1000+ I didnt want to touch them as for RFC lookup we will have to explicitly edit each mapping and change the lookup process.

But what I fail to understand is if this works for PI ABAP stack why doesnt it work for ECC. Isnt creating ABAP tables as good as they being placed on DB level?

gagandeep_batra
Active Contributor
0 Kudos

Can you directly try with same data with SQL editor

Regards

GB

Former Member
0 Kudos

Yeah it works there but what i noticed is in teh adapter the query gets formed this way when I use Native SQL as the protocol:

<?xml version="1.0" encoding="UTF-8" ?><ns1:lookup returnType="LinkedList" xmlns:ns1="http://sap.com/xi/lookup"><statement><table action="SQL_QUERY"><access>SELECT * FROM ZXI_LKUP_VENDOR WHERE ZEDI_INTERCHG_ID = &apos;9377778097633&apos; AND ZSAP_STATE = &apos;1&apos;;</access></table></statement></ns1:lookup>

The &apos; added instead of single quote( ' ) looks fishy to me. Any thoughts?


The error message looks like :

Error 'java.sql.SQLException: [SQL0104] Token < was not valid. Valid tokens: ( CL END GET SET CALL DROP FREE HOLD LOCK OPEN WITH ALTER BEGIN.' executing service raw2sql with SQL statement '<?xml version="1.0" encoding="UTF-8" ?><ns1:lookup returnType="LinkedList" xmlns:ns1="http://sap.com/xi/lookup"><statement><table action="SQL_QUERY"><access>SELECT * FROM ZXI_LKUP_VENDOR WHERE ZEDI_INTERCHG_ID = &apos;9377778097633&apos; AND ZSAP_STATE = &apos;1&apos;;</access></table></statement></ns1:lookup>'