cancel
Showing results for 
Search instead for 
Did you mean: 

Receiver FCC headerline

former_member621323
Participant
0 Kudos

Hi All,

  My target file will be like this...its a pipe delimited file.

Main Header

Header1 Header2 Header3 Header4 Header5

63747|1J27|005|1159.000|EA

63747|1J27|005|1159.000|EA

63747|1J27|005|1159.000|EA

Now I have achieved 2nd line by using record.AddHeaderLine = 3 and giving record.headerLine values as Header1,Header2 etc.

How can i write Main Header in my target file?...Pls help.

Thanks,

Praveen.

Accepted Solutions (0)

Answers (2)

Answers (2)

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Just a thought..  Can you try this way...

record1.headerLine = MainHeader

record1.addHeaderLine = 1

record2.headerLine = Header1,Header2,...Header5

record2.addHeaderLine = 3 or so.

former_member184681
Active Contributor
0 Kudos

Hi,

I'm afraid it won't work, unless record1 and record2 exist as nodes in the message payload. Here is what SAP Help says about the Recordset Structure:

If you want to convert all substructures using the same parameters, you only have to specify one structure. The entries are automatically applied to all substructures.

If you specify more than one structure, the list must contain all the structures occurring in the document. The list must be complete, otherwise a processing error will be triggered at runtime.

Regards,

Greg

former_member621323
Participant
0 Kudos

Hi Baskar,

   I already tried it,adding a extra hierarchy but it dint work.

former_member184681
Active Contributor
0 Kudos

Hi Praveen,

Try putting it all as the headerLine:

record.headerLine = Main Header '0x0D''0x0A'Header1 Header2 Header3 Header4 Header5

Regards,

Greg

former_member621323
Participant
0 Kudos

Hi Greg.

  I tried as you said,but its coming in the same line as other headers. I want Main Header in 1st line,in 2nd line the other headers.

Besides, what '0x0D''0x0A' stands for..??

Thanx,

Praveen

zameerf
Contributor
0 Kudos

It might not be the right way to handle, but you can try creating these two header lines as two record segmets in your mapping with one field in each and then add these two segments as well in receiver FCC without any addHeaderLine parameter. This you can try if nothing is actually working.

former_member184681
Active Contributor
0 Kudos

Dear Praveen,

These '0x0D''0x0A' are hex codes for Line Feed and Carriage Return, and that's exactly what they should do: split your header over two lines... You can try replacing it with 'nl', but I also doubt if it will work.

Regards,

Greg