cancel
Showing results for 
Search instead for 
Did you mean: 

Content is not allowed in prolog error

0 Kudos

Hi All,

  when executing JDBC to ECC scenario "Content is not allowed in prolog" is triggering under mapping. Applied

the solutions suggested by below links

  Restarted the message twice and removed SWCV also, still its giving me the same error.

error:

Note: Using PI 7.4 single stack and interface developed using ICO.

  Can anyone suggest possible solution to avoid this error.

Thanks,

Aman.

Accepted Solutions (0)

Answers (2)

Answers (2)

justin_santhanam
Active Contributor
0 Kudos

what is your message type name? put that Message type name in the Document Name

Thank you,

Justin.

0 Kudos

Thanks, message type name itself "resultset".

i send data without resultset from test message it executes, however IDOC receiver channel is giving error : IDOC_ERROR_PARSE_FAILURE: An IDocConversionException occurred while parsing IDoc-XML for type.

I mapped each segment and begin with "1" also main segments with constant.

justin_santhanam
Active Contributor
0 Kudos

Aman,

Please go to your message mapping .. Go to the Test tab and can you give the XML from there? I don't want you to execute anything, just copy the source xml and paste here..

Thank you,

Justin.

0 Kudos

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

<ns0:InventroyTansaction xmlns:ns0="urn:abc.com/dct/InventoryTransaction">

   <row>

      <PL_ID>Block</PL_ID>

      <TransactionId>130345</TransactionId>

      <TransactionType>I</TransactionType>

      <Location>L4543</Location>

      <ItemId>11456 </ItemId>

      <DateTime>2015-05-26 00:00:00.0</DateTime>

      <Qty>672</Qty>

      <CustomerId> </CustomerId>

      <OriginalPONumber>10014</OriginalPONumber>

      <UOM>EA</UOM>

      <TransferTo>L00015</TransferTo>

      <TransferFrom>8386</TransferFrom>

      <IUOrderID>10014</IUOrderID>

      <IULine>10000</IULine>

      <Description>Material Charged To K.O.`s    </Description>

      <ScheduleAgID>Material Charged To K.O.`s    </ScheduleAgID>

      <CurrentDate>2015-11-25 14:16:19.57</CurrentDate>

      <Processed>0</Processed>

   </row>

above I executed under mapping and it went well. however actual one having resultset before row.

one row of data am pasting here

justin_santhanam
Active Contributor
0 Kudos

Thanks for providing. This is the reason I asked you this.. You said resultset is your message type name, but based on the XML you provided, your message type name is InventroyTransaction. So please maintain the comm.channel like below

JDBC Comm.Channel - Processing tab

Document Name  InventroyTransaction

Document Namespace urn:abc.com/dct/InventoryTransaction

-Justin.

0 Kudos

I used two messagetypes for resultset . one with resultset->rows->fields  rows->fields. its fixed.

however am stuck with idoc parser error.

Error before sending due to idoc parsing error: (7) IDOC_ERROR_PARSE_FAILURE: An i folled <MBGMCR02>:

state=READING_FIELD_VALUE_TAG, charPosition=836, lineNumber=1, columnNumber=837

I gone through this scn link for this error. segment and begin mapped with 1 still getting the same error. i reprocessed the message still no luck

wonder it works fine when passing no data. any idea(expect applying that note)

0 Kudos

Functional team has changed the data . They have the logic at DB end to convert char to numeric, however its not sending as numeric value from DB leads failure in PI. Issue resolved with correct data. Thanks

justin_santhanam
Active Contributor
0 Kudos

Can you paste the payload here? Need to see how the data you received from JDBC. Don't paste everything, just with one row

Thank you,

Justin.

0 Kudos

Content-ID:<soap-73c6562592ef11e59c0700000060dddb@sap.com>

Content-Type:text/xml; charset=utf-8

Content-Disposition:attachment;filename="soap-73c6562592ef11e59c0700000060dddb@sap.com.xml"

Content-Description:SOAP

<SOAP:Envelope xmlns:SOAP='http://schemas.xmlsoap.org/soap/envelope/'><SOAP:Header xmlns:sap='http://sap.com/xi/XI/Message/30' versionMajor='3' versionMinor='1' SOAP:mustUnderstand='1'><sap:Main versionMajor='3' versionMinor='1' SOAP:mustUnderstand='1'><sap:MessageClass>ApplicationMessage</sap:MessageClass><sap:ProcessingMode>asynchronous</sap:ProcessingMode><sap:MessageId>718feb22-92ef-11e5-99ab-00000060dddb</sap:MessageId><sap:TimeSent>2015-11-24T21:08:03Z</sap:TimeSent><sap:Sender><sap:Party agency='http://sap.com/xi/XI' scheme='XIParty'></sap:Party><sap:Service>XXXXX</sap:Service></sap:Sender><sap:Receiver><sap:Party agency='http://sap.com/xi/XI' scheme='XIParty'></sap:Party><sap:Service>XXXXX</sap:Service></sap:Receiver><sap:Interface namespace='xxxx'>xxxx</sap:Interface></sap:Main><sap:ReliableMessaging SOAP:mustUnderstand='1'><sap:QualityOfService>ExactlyOnce</sap:QualityOfService></sap:ReliableMessaging><sap:System SOAP:mustUnderstand='1'><sap:Record namespace='http://sap.com/xi/XI/Message/30/general' name='interfaceDeterminationGUID'>19ecb01392f511e5ac2700000060ddda</sap:Record><sap:Record namespace='http://sap.com/xi/XI/Message/30/general' name='senderAgreementGUID'>492b4ad03b7434408efe84cee3e6e198</sap:Record></sap:System><sap:DynamicConfiguration SOAP:mustUnderstand='1'><sap:Record namespace='http://sap.com/xi/XI/Message/30/routing' name='InterfaceDeterminationHash'>1bb1ffa08e3982701f63e9d3e1fcd682</sap:Record><sap:Record namespace='http://sap.com/xi/XI/Message/30/general' name='senderAgreementGUID'>492b4ad03b7434408efe84cee3e6e198</sap:Record></sap:DynamicConfiguration><sap:HopList SOAP:mustUnderstand='1'><sap:Hop timeStamp='2015-11-24T21:08:03Z' wasRead='false'><sap:Engine type='AE'>af.di1.gmcrwspidv</sap:Engine><sap:Adapter namespace='http://sap.com/xi/XI/System'>XIRA</sap:Adapter><sap:MessageId>718feb22-92ef-11e5-99ab-00000060dddb</sap:MessageId></sap:Hop></sap:HopList></SOAP:Header><SOAP:Body><sap:Manifest xmlns:sap='http://sap.com/xi/XI/Message/30' xmlns:xlink='http://www.w3.org/1999/xlink'><sap:Payload xlink:type='simple' xlink:href='cid:payload-7306cb3792ef11e5a87200000060dddb@sap.com'><sap:Name>MainDocument</sap:Name><sap:Description></sap:Description><sap:Type>Application</sap:Type></sap:Payload></sap:Manifest></SOAP:Body></SOAP:Envelope>Content-ID:<payload-7306cb3792ef11e5a87200000060dddb@sap.com>

Content-Disposition:attachment;filename="MainDocument.xml"

Content-Type:application/xml

Content-Description:MainDocument

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

<resultset>

  <row>

  <PL_ID>M</PL_ID>

  <TransactionId>130572047</TransactionId>

  <TransactionType>IM</TransactionType>

  <Location>Er101</Location>

  <ItemId>119056 </ItemId>

  <DateTime>2015-05-26 00:00:00.0</DateTime>

  <Qty>672</Qty>

Note: I've replace the interface name and some other details with "XXXXX".

         Message attached was from message monitoring from incoming message

justin_santhanam
Active Contributor
0 Kudos

Hi Aman,

If you copy and paste this in your mapping program, does it work? ( including the remaining  part of XML as well)..

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

<resultset>

  <row>

  <PL_ID>M</PL_ID>

  <TransactionId>130572047</TransactionId>

  <TransactionType>IM</TransactionType>

  <Location>Er101</Location>

  <ItemId>119056 </ItemId>

  <DateTime>2015-05-26 00:00:00.0</DateTime>

  <Qty>672</Qty>

Thank you,

Justin.

0 Kudos

Thanks Justin. When importing the same payload , its failing to execute mapping. After not using resultset mapping its  positive. Message generated from sender side with resultset.

Two more issues

1. one of the filed of source structure starting with numeric eg: 3PL and under PI we cant define fields with numeric.Since DB structure was defined in that way ,  PI  source structure to be to define the same way even no mapping and no usage of that field. If this field was not defined under PI , its failing at mapping level because of incoming message has this field.

2. Some additional fields which are not used and mapped in PI are having in source DB side coming into PI causing mapping fail in PI as those fields are not defined in PI sender structure.

these are the observations i found. Any light to avoid these would be appreciated.

Aman

justin_santhanam
Active Contributor
0 Kudos

Can you show  screenshot of your sender JDBC comm.channel?

Are you using Select query or some Stored Procedure? If you are using Select Query, then it's pretty straight forward for issue 1 - Select 3PL as PL from *************, so that the query will give you the field name as PL and it's good on PI end..

Just provide more information, it will be easy for us to help!

0 Kudos

Am using select query only. Thanks I'll update under select query.

when am using this structure its failing under mapping

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

<resultset>

  <row>

  <PL_ID>M</PL_ID>

  <TransactionId>130572047</TransactionId>

  <TransactionType>IM</TransactionType>

  <Location>Er101</Location>

  <ItemId>119056 </ItemId>

  <DateTime>2015-05-26 00:00:00.0</DateTime>

  <Qty>672</Qty>

how to avoid resultset generation from source structure. When I select the incoming message from DB its starting with resultset. Do we required to define resultset->row->fields or row->fields is accurate. 

0 Kudos