cancel
Showing results for 
Search instead for 
Did you mean: 

Error in File to IDOC Scenario

Former Member
0 Kudos

Hello All

I am working on the scenario FILE to IDOC. I tested in the mapping editor, it worked fine. But When I tested using a .dat file I am getting error -

During the application mapping com/sap/xi/tf/_MM_SHPCON_Medusa_to_DELVRY03_ a com.sap.aii.utilxi.misc.api.BaseRuntimeException was thrown: Fatal Error: com.sap.engine.lib.xml.parser.Parser

I cannot test using the payload from SXMB_MONI because the payload is same as the contents in file.

Is there anything that I am missing here?

Thanks

Naga

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hey ,

you need to use File content conversion. As XI only understands xml.

FCC is basically used to convert the input file format in xml.

You need to use certain parameters in your file channel.

you can refer to these links.

This blog is about how to use FCC..

This link will give you the information on all the parameters for the sender file.

http://help.sap.com/saphelp_nw04/helpdata/en/44/79973cc73af456e10000000a114084/frameset.htm

regards,

Milan

Answers (9)

Answers (9)

Former Member
0 Kudos

Thanks to Sukarna and Gaurav.

Former Member
0 Kudos

The problem is resolved.

Thanks Gaurav.

Naga

Former Member
0 Kudos

Gaurav

I am still getting the same error.

Thanks

Naga

Former Member
0 Kudos

I am using Content conversion now. Data is the flat file is like:

HDR|Field1|Field2|Field3|......|

TRK|Field1|Field2|Field3|......|

DTL|Field1|Field2|Field3|.......|

In the FCC, For HDR

HDR.keyFieldValue HDR

HDR.fieldFixedLengths 3,7,20,35,35,12,......

HDR.fieldNames Record_Id,Order_Number,Reference_Number,PO_Number,Third_Party_No,EDI_Trading_Partner,H01.key

FieldInStructure add

H01.lastFieldsOptional YES

H02.endSeparator |

H01.fixedLengthTooShortHandling CUT

H01.fieldFixedType char

In the Communication channel I see the error:

- 2008-10-03 13:55:00 EDT: Error: Conversion of complete file content of 'SHPCON_CSL_20081002.dat' to XML format failed around position 0: Exception: ERROR converting document line no. 1 according to structure 'HDR':java.lang.Exception: Consistency error: field(s) missing - specify 'lastFieldsOptional' parameter to allow this

Can somebody help me why this error is coming?

Thanks

Naga

Former Member
0 Kudos

HI

i think after HDR finishes new line starts right?

use the end seprater as nl

and astFieldsOptional is a kind of obsolete dont use this.

If the last field only is shorter than defined or is missing completely, the conversion is executed. The contents of the last field are then applied to the XML element as found. Consequently, the value can be incomplete or empty.

You can change this behavior by using the parameters NameA.missingLastFields and NameA.additionalLastFields

Thanks

Gaurav

Edited by: Gaurav Bhargava on Oct 4, 2008 1:12 AM

Former Member
0 Kudos

The problem seems for now in FCC, so follow this blog..

Former Member
0 Kudos

Hi Naga,

I thought, this is the mapping error. try to find out the data.

If data is correctly, there is no mapping error not found

and check ur target IDOC Structure. is it correctly defined, in some cases some of the fields are diabled.

Regards,

Sateesh

Former Member
0 Kudos
Former Member
0 Kudos

I just came to know about that seeing some other interface in our system but I do not understand what that is. Could you please explain how I have to fill the parameters for content Conversion.

Former Member
0 Kudos

Naga,

Did you use the content conversion...

If Yes....you can check those content conversion parameters in Sender communicaiton channel.

-S

Former Member
0 Kudos

below links shd help u,first try to configure your self by using these links and let us know if you face problems.

http://help.sap.com/saphelp_nw04/helpdata/en/2c/181077dd7d6b4ea6a8029b20bf7e55/content.htm

http://www.riyaz.net/blog/xipi-file-content-conversion-for-complex-structures/

Former Member
0 Kudos

I am not able to use the payload becasue it is same as .dat file. File is pipe delimeted.

Former Member
0 Kudos

did you use Content conversion in your FCC??

Former Member
0 Kudos

Hey,

Take the pay load from the sxmb_moni and test with the pay load in IR - MM - Test tab.

Since its Runtime exception error..there might be problem with your mapping...

-S