Skip to Content
author's profile photo Former Member
Former Member

mapping idoc to flat file

Hi Friends

I Have to map one idoc to cvs flat file , the file structure has 10 fields , those 10 fields have to be repeated as many times as there is segments in the idoc for instance

the first line takes segmenta A and the second line takes segment B and so on

segment A goes to line 1 f1 f2 f3 f4 f5 f6 f7 f8 f9 f10

segment B goes to line 2 f1 f2 f3 f4 f5 f6 f7 f8 f9 f10

segment n goes to line n f1 f2 f3 f4 f5 f6 f7 f8 f9 f10

how ca I best do that and does any one have a solution example.

many thanks in advance.

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Nov 29, 2007 at 11:52 AM

    Do like this,

    Create the target structure like this:

    <b>Records</b> with 0.....unbound

    -<b>Line1</b> with 0---unbound

    -


    Field1 with 0:1

    -


    Field2 with 0:1

    -


    Field3 with 0:1 (and so on...upto Filed10)

    ---<b>Line2</b>

    -


    Field1 with 0:1

    -


    Field2 with 0:1

    -


    Field3 with 0:1 (and so on upto Field10)

    *

    *

    *

    *

    uto n..

    Now map the IDOC segments to Line1, Line2...upto n.. & aslo map the respective fields of idoc to field1, field2, and so on....

    Use FCC in ID to convert it into CSV see the below mentioned blog.

    <b>File Receiver with Content Conversion</b>

    /people/arpit.seth/blog/2005/06/02/file-receiver-with-content-conversion

    I hope it will help you to get your result.

    Regards,

    Sarvesh

    ****Rewards Points for helpful ans..

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Hi sarvesh

      nice job.

      It seems to work , I have tried 3 lines with differents segments fields value and tested it , it works fine so far.

      Thanks for your help , and may I get back to you if I meet any problem .

      regrads

  • author's profile photo Former Member
    Former Member
    Posted on Nov 29, 2007 at 11:27 AM

    simply map segment to line

    provided that node line has set to maxoccur

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.