cancel
Showing results for 
Search instead for 
Did you mean: 

Text File - to- XMLFile scenario Conditions

Former Member
0 Kudos

Hi friends,

Sorry for the posting same question.. but I did't clear with answers.. so, plz give me a suggestion..

My Text File contain data like this

<b>MAT_NO . MAT_NAME</b> M1 . MONITOR

M2 . PROCESSOR

M3 . USB

<b>MAT_NO . MAT_NAME</b> M3 . HARD DISK

M4 . KEYBOARD

<b>MAT_NO . MAT_NAME</b> M5 . CHIPS

M6 . CABLES

Ect.............................................

the above is my Text file.. now i want to load this file into XI and the output is in XML format..

but the requirement is i want to skip All the Headers.. and i need to load only the data .. how can i skip all the headers from my Text file.. there are lot of headers are repeating there...

for this what can i do... is it enough to Content Conversion or we need to do any other conditions also... can u plz give me the steps for this..

Thanks

BABU

Accepted Solutions (1)

Accepted Solutions (1)

santhosh_kumarv
Active Contributor
0 Kudos

Hi Babu,

Can u also provide the source and target data type structure with its occurance and the FCC u are using...

Regards

San

Former Member
0 Kudos

HI,

My source structure is

SENER_DT_OB

Material details

. Material _Information

. MAT_NO

. MAT_NAME

like this.. two main SUB HEADER ELEMENTS.. AND UNDER THAT ORINAL TWO FIELDS.. the same structure in Receiver side also..

Thanks

BAbu

santhosh_kumarv
Active Contributor
0 Kudos

Well Babu, could u provide the data type structure clearly and also the FCC.

>>two main SUB HEADER ELEMENTS.. AND UNDER THAT ORINAL TWO FIELDS

The DT in your previous reply is not clear.

Regards

San

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi Babu

HI,

as per you your source structure is

SENER_DT_OB

Material details

. Material _Information

. MAT_NO

. MAT_NAME

like this.. two main SUB HEADER ELEMENTS.. AND UNDER THAT ORINAL TWO FIELDS.. the same structure in Receiver side also..

please give the complete structure so that i can provide the exact solution for this, and please provide with the occurence.

Thanks

Rinku

Former Member
0 Kudos

Hi Rinku,

thanks for ur reply.. here i'm giving my original structure..

SENER_DT_OB

. . MATERIAL DETAILS -


1: 1

. .Material _Information -


0: UNBOUNDED

. . MAT_NO -


1:1

. . . MAT_NAME -


1:1

AND MY RECIVER STRUCTURE IS

RECEIVER_DT_OB

. . MATERIAL DETAILS -


1: 1

. .Material _Information -


0: UNBOUNDED

. . MAT_NO -


1:1

. . . MAT_NAME -


1:1

so, what i have to mention in the file content conversion..

THANKS

Babu

Former Member
0 Kudos

Hi Babu

as per your source structure and the target structure you want only the material no and material name in the target file right?

if i am right you have to do the mapping like that

you can map material information on the target side with the constant if you diont require it multiple time in the target structure.

note:the parent node in ur target does not depend on any filed because for each field the occurence is only one so it will occur only once in each file.

if you require it multiple times then map it with the field or node on which it depends

and do one to one mapping for all other fields.

please reply me back if you still need any clarification

Thanks

Rinku

Former Member
0 Kudos

Hi Friends,

Can someone provide me a scenario for text to XML file scenarios.

Also please let me know the useful blogs related to XI and its different scenarios

Thanks much.

Regards,

Sanjay

Former Member
0 Kudos

Hi,

I dont think we have such option in content convertion to remove header level....we can skip some rows but not repeating headers.

Tel me when the header will be repeating.....after any fixed rows it will repeat the v can try to write any UDF for this.

Send Target side structure and give ur requirement clearly.

Regards,

Phani

Former Member
0 Kudos

Hi babu

can you please provide the source data type and the target data type structure you have created .

and you can use the following parameters for the content conversion at the sender communication channel if your structure is look like as below

RECORD.fieldSeparator :,

RECORD.fieldNames :KEY,FNAME,LNAME,AGE

RECORD.keyFieldValue :1

DETAIL.fieldSeparatr :,

DETAIL.fieldNames :KEY,SALARY,EMPID

DETAIL.fieldNames :2

Note:these parameters are accoding to the structure given below.

suppose you have a structure like as below

data (0..unbounded)

record (0..unbounded)

key (1..1)

fname (1..1)

lname (1..1)

age (1..1)

detail (0..unbounded)

key (1..1)

salary (1..1)

empid (1..1)

please reply back if still have the problem

Thanks

Rinku

Former Member
0 Kudos

Hi Babu

in the Message mapping please do not map the header data with the target.

Thanks

Rinku