cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping issue

former_member188791
Participant
0 Kudos

we have the following requirement:

there is a field called sequence number which is appearching in 4 nodes in the source (all the nodes are optional 0 to unbound ,and contains same value),need to populate sequence value in the target node even one single node at source contains value.

Can any body suggest

Accepted Solutions (0)

Answers (6)

Answers (6)

Former Member
0 Kudos

source node -> Field -> remove Context -> collapse Context -> equals with "" -> if without else -> and in the second input of if give the output of collapse context -> target field.

According to this it will take even if a single value is present in the source side and map it to target else it'll igonre.

Former Member
0 Kudos

Hi Rajiv,

Please try this if it works for you,

SeqNumber--->removecontex->exists->splitbyvalue-Eachvalue---->target.

Thanks and regards,

Ram.

anupam_ghosh2
Active Contributor
0 Kudos

Hi,

You can try with this UDF of type Context


public void passValues(String[] a,ResultList result,Container container){
int i;

for(i=0;i<a.length;++i)
{
          result.addValue(a<i>);	
}


}

sequence number(source) -


>UDF------> Sequence number (target)

Regards

Anupam

naveen_chichili
Active Contributor
0 Kudos

Hi Raj,

I think you can try with use oneasmany .

Regards,

Naveen

markangelo_dihiansan
Active Contributor
0 Kudos

Hello,

there is a field called sequence number which is appearching in 4 nodes in the source (all the nodes are optional 0 to unbound ,and contains same value),need to populate sequence value in the target node even one single node at source contains value.

Not sure what you meant by sequence value. Did you mean it like this?


SeqNum -> removeContext -> count -> Target

or


SeqNum -> removeContext -> Index: 1..1 -> SplitByValue:eachValue -> Target

Regards,

Mark

former_member472138
Active Contributor
0 Kudos

Use exits function with condition(if-else).