cancel
Showing results for 
Search instead for 
Did you mean: 

skip the record when suppressed by using UDF

swapna_patha
Explorer
0 Kudos

hi All,

my requirement is

Source contains different records which are under some header, i want to create a segment at the target side with the value from the record, like if the record contain feild Debit/Credit = DR then the GL segment should be created.

Source suructure

<Request_Key>

     <Header>

          Record(1)

               Debit/credit value : DR

          Record(2)

               Debit/Credit value : CR

     </Header>

</Request_Key>

<Request_Key>

     <Header>

          Record(3)

               Debit/credit value : DR

          Record(4)

               Debit/Credit value : DR

     </Header>

</Request_Key>

at the target i have created 2 IDOC for each Request_Key and i need to crete GL segment for each header record which contains the Debit/Credit value as DR

Target as follows:

first IDOC with GL segment for record(1)

sencond IDOC with 2 GL segments for Recorde 3 and 4.

i have tried with remove context and split value but not working.

please suggest the UDF to skop the GL segment for record 2 and create GL for record 3 and 4.

Thanks

Accepted Solutions (1)

Accepted Solutions (1)

sahithi_moparthi
Contributor
0 Kudos


Hi,

Use RemoveSuppress UDF.It will remove the Suppress value in the queue.

for (int i = 0; i < var1.length; i++) {

if (var1[i]!=ResultList.SUPPRESS )

{

  result.addValue(var1[i]);

}

}

swapna_patha
Explorer
0 Kudos

Thanks it worked

Answers (0)