cancel
Showing results for 
Search instead for 
Did you mean: 

File to File with Validation For Empty Line

Former Member
0 Kudos

Hi Experts,

My Scenario:

FIle -> PI -> ABAP Proxy

For the File sender i am using File Content Conversion for .TXT. It is working fine but sometimes the user create the .TXT fiile with empty space/tab after the last record. The users wrongly press enter at the last record at the .TXT. Please look below:

1 test1 kl

2 test2 sg

3 test3 mk

|

Please look above the user wrongly press ENTER '|' and it created empty tab below the last record.

How can i validate the sender data if there is empty space and i should not transfer to receiver.

I am trying to use UDF but could anyone guide me?

Thank you

saravannan

Accepted Solutions (0)

Answers (4)

Answers (4)

baskar_gopalakrishnan2
Active Contributor
0 Kudos

There are few steps to be done. First you have to convert the txt file to xml file using FCC successfully. You might need to use ignoreadditionalfields option in the configuration. Refer sap help document provided by previous expert. Once you successfully convert txt file to XML file then use xpath expression edition in receiver determination and decide whether to input reciever system or not.

abhay_rajhans2
Contributor
0 Kudos

Hi,

You can refer following link which helps for content conversion. In that speically the last parameter.

http://help.sap.com/saphelp_nw04/helpdata/en/e3/94007075cae04f930cc4c034e411e1/frameset.htm

Former Member
0 Kudos

hi mrsaravannan,

i think you can handle it in your content conversion itself.. based on how you are doing it.. additionalLastfields to be set as ignore.. i am not sure if i understood your question wrong?

monicabhosale
Active Participant
0 Kudos

Hello,

In receiver determination you can write that if your all fields(mandetory) are not empty then to for your perticular receiver and for If no receiver found option select end message without Error so if you some fields are coming blank or last line coming blank then it will not send message to your receiver and and without any error.

Monica