cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping Issue

Former Member
0 Kudos

Hi All,

I am working on File to IDOC to File Scenario where I need to create multiple records based on a particular filed. I am able to create by using split by value but one of the field is not paupulating value.. Its getting populated only first time ...second time its giving a blank value, Structures are as below:

IDOC

--

-Field1--0..1

-Field2--0..1

-Field3--0..1

-Field4--0..1

-Field5--0..1

Flat File Strcuture:

Row

FieldA1--1

FieldB1--1

FieldC1--1

FieldD1--1

Field2 is the filed up on which number of Rows needs to be generated. so I mapped Field2>SpiltByValue (Each Value)>CollapseContext-->Row

FiledC is the Field which is not getting its value populated from the second iteration. I mapped as follow:

Filed3 Exist then Field4 Equals A then Field3 Equals 99 or 100 then Y else N-->Remove Context mapped to FieldC

Sample Data is as follow:

IDOC

<SEGMENT>

---Field1<Const1>

---Field2<A>

---Field3<99>

---Field4<Con3>

---Field5<Con4>

</SEGMENT>

<SEGMENT>

---Field1<Const1>

---Field2<B>

---Field3<99>

---Field4<Con3>

---Field5<Con4>

</SEGMENT>

Flat File Strcuture:

Row

--FieldA<Const1>

--FieldB<A>

--FieldC<N>

--FieldD<Con3>

Row

--FieldA<Const1>

--FieldB<B>

--FieldC<>

--FieldD<Con3>

Any inputs why I cant able to get the value in the FiledC? I tried with Remove conext but it ddint worked.

Thanks

Rajeev.

Accepted Solutions (1)

Accepted Solutions (1)

former_member200962
Active Contributor
0 Kudos
Its getting populated only first time ...second time its giving a blank value

This indicates that the context is not set properly....if you try to create third value even it will be blank....only the ifrst reference of the source node is taken into consideration

So just make sure that the Context change logic is applied properly (raise context/ remove context/ collapse context)

Regards,

Abhishek.

Former Member
0 Kudos

Hi,

I tried with different options and it worked ONly when I removed one condition in the mapping..

I used Field3 Exist then only conditon (To check if the field exist then only go further with the condition orlese pass Empty value).. If I remove this condition then it worked..

Thanks alot

Rajeev

Answers (0)