on 04-12-2011 9:08 PM
Hi All,
I need a help for one of mapping function "exists" usage:
When source filed <F1> value doesn't exists in source payload then drop <target_segment1 0: 999999>.
It means <F1> value not coming with source, then I do not want display entire <target_segment1> in receiver side.
my logic should be like this , can you help me to what functions for implement this :
If ( <F1> -
>exists) then <F1> map into <target_segment1> else drop the <target_segment1>
Note: under <target_segment1> there are multiple fields: so when <F1> value not coming with source, so total segment and under fields not display in receiver side.
Thanks,
Ravi Shankar.
its simple.
use if with exist and map it to header node. if source does not exist the header and all the fields under it will not be sent.
Thanks
Inder
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
<<use if with exist and map it to header node. if source does not exist the header and all the fields under it will not be sent.>>
It seems to simple, I tried as it is with map header node , but it is not dropping header node, that's what i posted this question:
for example source file :
<L>
L11,, 2345
L12,2345, 3456
L13, 8976,4567
</L>
In above L11_01 = "" (---> null)
L12_01 = "2345"
L13_01 = "8976"
I tried like this for header node::
If <L11 01> -->exists then <L1101> map into <L> ;
In this case <L11_01> value doesn't exists, so I need to drop the entire row . Out put required like this:
L12,2345, 3456
L13, 8976,4567
But out put coming like this(as it is same like source) :
L11,, 2345
L12,2345, 3456
L13, 8976,4567
Any idea now:
Thanks,
Shankar-
Shankar,
You can follow the following approach:
Source field -
> not-->equalsS blank->Ifwithoutelse--->createif>Target
Source field -
> then-->
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Use exits and createif functions
F1Node --> exits ---> createif ---> Targetnode
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
11 | |
10 | |
9 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.