cancel
Showing results for 
Search instead for 
Did you mean: 

FCC Send File Adapter - missingLastFields not working

Former Member
0 Kudos

Hi

I have a flat file to capture using the sender File adapter

Parameter as follows:

Header_fieldNames : Key,Name,StaffID,Telephone

Header_fieldFixedLengths : 2,12,10,8

Header_endSeparator : 'nl'

Line_fieldNames : Key,Address,Company,LineText

Line_fieldFixedLengths : 2,20,20,40

However there are times where last field come in missing.

Hence I use the Header_missingLastFields : error

Line_missingLastFields : error

However it does not seem to be working as the adapter fails to pick the file from the FTP folder

but if I replace error with ignore, the sender adapter picked the files and process and send to the receiver adapter.

I need to flagged error in sxmb_moni if last field or last few fields are missing....any advise how could this be achieve ?

Regards

Fred

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

My apology,

i have also created the Header.keyFieldValue :01

Line.keyFieldValue :02

If the flat file is sending records with all fields , no issue.

BTW, I am sending from Flat file to IDOC

Please note that for simplify my situation the actual numbers of fields for both header and line are more and different.

Would you kind enough to explain how to raise an error in the mapping or alert ?

Former Member
0 Kudos

Fred, make sure that the occurance of the fields are mandatory. If any of the field value is missed then would raise an alert.

Thanks,

Former Member
0 Kudos

Hi Fred,

Check this blog for creating an alert from a User defined Function in Mapping.

/people/bhavesh.kantilal/blog/2006/07/25/triggering-xi-alerts-from-a-user-defined-function

hope it helps,

regards,

francis

Former Member
0 Kudos

Hi,

chk this also:

/people/alessandro.guarneri/blog/2006/01/26/throwing-smart-exceptions-in-xi-graphical-mapping

Thanks

Amit

Former Member
0 Kudos

try giving Line_endSeparator : 'nl'

it may work .

regards

Ravi anand

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Fred,

When u give Line_missingLastFields : error, it throws an error in the adapter engine only when the last field is missing.

If you want to throw an error in moni, u can do it by giving the Line_missingLastFields : ignore as you did now.

the file will be picked up and in the mapping, u can chcek whether the fileds occured or not, if last fields didnt occur then an exception can be raised using the mapping.

Please let me know if you need any more help.

Thanks,

Hemanth.

Former Member
0 Kudos

Hi Fred,

nameA.keyfieldvalue should be specified and must be with different values.

If you would like to ignore the key field value, then use the paramter nameA.keyFieldInStructure-Ignore.

Refer the weblink below for the Sender file Adapter content conversion parameters:

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

Thanks,

Former Member
0 Kudos

Hi Freddy,

I think you might like to specify missingLastFields = add. then it will add the missing fields as empty. you can further check if these are empty in mapping and then fail the message or create an alert.

If you specify "ignore" then you will not get those fields in your structure and if you specify "error" then the file will not be picked up.

have a look here

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

....

missingLastfields

If the inbound structure has less fields than specified in the configuration then the XML outbound structure is created as follows:

○ ignore

Outbound structure only contains the fields in the inbound structure

○ add

Outbound structure contains all fields from the configuration; the fields missing in the inbound structure are empty.

○ error

Conversion is terminated due to the incomplete inbound structure. An error message is displayed

....

regards,

francis