cancel
Showing results for 
Search instead for 
Did you mean: 

DT for File Content Conversion scenario

Former Member
0 Kudos

Hi Guys,

I am working on IDOC to file scenario in which I want to know which type of DT should I go for?

DT_Type

....Row

......Filed1

......Filed2

......Field3

...Row

DT_Type

Or

DT_Type

..Details

....Row

......Filed1

......Filed2

......Field3

...Row

..Details

DT_Type

I am going for Receiver Content conversion as I need to produce Flat like, I have about 30 filed names and I am wondering is it possible not ot mention field names in Content conversion?

What is the parameter to place to get a new line after each record? I am using row.endSeparator as 'nl' I am getting some special character instead of starting a new record in next line.

Thanks

Rajeev

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Rajeev,

Please go with datatype 1 and instead of 'nl' try to put '0x0D''0x0A' and see. Sometimes the special character is with your editor. Try to open the same file in other editor like textpad, wordpad, notepad etc.

FieldNames is important so please give them.

Regards,

---Satish

Answers (1)

Answers (1)

Shabarish_Nair
Active Contributor
0 Kudos

>

> Hi Guys,

>

> I am working on IDOC to file scenario in which I want to know which type of DT should I go for?

>

> DT_Type

> ....Row

> ......Filed1

> ......Filed2

> ......Field3

> ...Row

> DT_Type

>

>

> Or

>

> DT_Type

> ..Details

> ....Row

> ......Filed1

> ......Filed2

> ......Field3

> ...Row

> ..Details

> DT_Type

>

> I am going for Receiver Content conversion as I need to produce Flat like, I have about 30 filed names and I am wondering is it possible not ot mention field names in Content conversion?

>

> What is the parameter to place to get a new line after each record? I am using row.endSeparator as 'nl' I am getting some special character instead of starting a new record in next line.

>

>

> Thanks

> Rajeev

do ref: /people/shabarish.vijayakumar/blog/2007/08/03/file-adapter-receiver--are-we-really-sure-about-the-concepts to have a better understanding.

in your case DT 1 should be better.

Former Member
0 Kudos

Hi,

Thanks for your input and Vijaya thanks for the blog.

If IDOC contains one IDOC informaiton then there should be one file and if the IDOC contains multiple IDOCs then a single file shoud contain all IDOC ifnormation in a row. How does it possible?

Thanks

Rajeev.

Former Member
0 Kudos

Hi Rajeev,

In the mapping you map the source side idoc node (where your multiple idocs comes under one node that node) to target side Row field (at the time of data type creation you should create this as 0..Unbound). then howmany idocs come then that many number of rows created in the target file.

Regards

Ramesh.

Former Member
0 Kudos

Hi,

How should I map if the IDOC fields are 2-3 levels down the node to the FLAT File DT:

IDOC

...Seg1

......Field1

......Field2

.........Node1 -


0..UNBOUND

............N1

............N2

..............Node2 -


0..UNBOUND

.................N3

DT strcuture is with 0..Unbound

DT_Message

..Row

....Field1

....Field2

....N1

....N2

....N3

Thanks

Rajeev

Former Member
0 Kudos

Hi Rajeev,

Idoc node (for ex: orders.orders05) is 1..unbound or 0..unbound so you should map the IDoc node to Row node in the target side. so howmany times idoc comes that many number of times the file record repeats. Remaining fields we can map according to our requirement.

Regards

Ramesh

Former Member
0 Kudos

Idoc Node is 1..1

So If I map IDOC node to row node and fields to fields then its done? how about the segment nodes, no need to map at all?

Thanks

Rajeev

Former Member
0 Kudos

Hi Rajeev,

UseOneAsMany node function will help you to resolve your mapping.

If you give the full requirement and file fields occurance then we may betterly help you.

Regards

Ramesh

Former Member
0 Kudos

HI,

The SOURCE IDOC strcuture is:

IDOCNAME----


1..1

>IDOC--


1..1

>BEGIN--


required

>EDI_DC40--


1..1 (it has sub nodes but not required)

>E1KNAM1--


1..1

-


>SEGMENT----


Required

-


>Werks----


0..1

-


>Z1KNU2----


0..1 (SUB SEGMENT OF E1KNAM1)

-


>ZNUM----


0..1

-


>Z1ADD----


0..7 (SUB SEGMENT OF E1KNAM1)

-


>PostCode----


0..1

-


>E1KAVVM----


0..999(SUB SEGMENT OF E1KNAM1)

-


>VTWEG----


0..1

-


>LOVEM----


0..1

-


>E1KAVPM----


0..999(SUB SEGMENT OF E1KNAM1)

-


>KUNN2----


0..1

-


>Z1KAN--


0..1 (SUB SEGMENT OF E1KAVPM---(SUB SEGMENT OF E1KNAM1))

-


>NAME1----


0..1

Target File structure is:

MT_Type----


1..1

Row--


0..Unbound

-


Filed1----


0..Unbound

-


Filed2----


0..Unbound

-


Filed3----


0..Unbound

-


Filed4----


0..Unbound

-


Filed5----


0..Unbound

-


Filed6----


0..Unbound

if IDOC contains one IDOC data then it has to generate one file .. If IDOC contains more than one IDOC information then it has to generate one file with multiple IDOC informaiton in it.

how this can be achieved?

Thanks

Rajeev

Former Member
0 Kudos

Hi

if IDOC contains one IDOC data then it has to generate one file .. If IDOC contains more than one IDOC information then it has to generate one file with multiple IDOC information in it.

Do you mean to say processing with multiple IDOCs??? Please confirm about this because your IDOC occurance is 1..1

If you need to handle the multiple occurrences in one file, then make the IDOC 1..Unbounded and map it with the ROW field from File side Structure. It will help you to create one line per IDOC.

If there will be single IDOC, then only one row will be created in file.

thanks

Swarup