on 03-24-2011 12:30 PM
Hi
Scenario - File to IDOC, Occurance is only once.
What I want?
Souce fields: SOAKNUM, SOAFF1, SOAFF2, SOAFF3, SOAFF4
Target Idoc fileds: KLASH, DDNUM, DDDAT, DDVAL, DDCOUNT , CHKVAL
I'm generating an IDoc basing upon SOAKNUM.
Now I want to check the value of CHKVAL = DK and to map the field soaff1 --> DDNUM
check the value of CHKVAL = Dz and to map the field soaff2 --> DDVAL
Regards
S.
Souce FILE fields: SOAKNUM, SOAFF1, SOAFF2, SOAFF3, SOAFF4
Target Idoc fileds:
IDOC
SEGMENT1
-->KLASH
-->DDNUM
SEGMENT2
-->DDDAT
-->DDVAL
SEGMENT3
-->DDCOUNT
-->CHKVAL
Here CHKVAL is hardcoded with constant with the value DK.
source and target fields are mapped like SOAKNUM -- KLASH; SOAFF1-->DDNUM; SOAFF2 >DDDAT; SOAFF3>DDCOUNT this. Now I want to check If CHKVAL is DK and then map SOAFF1-->DDNUM.
I am not sure how to check this. Pls can some one explain how to check this condition.
Rgds
Swarna
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
ok so do you mean to say "CHKVAL" belongs to SEGMENT3 and you want multiple occurrence of SEGMENT3
and need to provide different constant to field CHKVAL
and need to check field CHKVAL for mapping for field.. SOAFF1-->DDNUM then yes can do it..
first let me know
as DDNUM belongs to SEGMENT1 then in that case what is the occurrence of SEGMENT1 if this is also multiple then yes you can put condition by using if else.
on duplication of target structure..
if SEGMENT3 occurrence is multiple then yes in mapping only you can duplicate SEGMENT3 structure and map different constant to CHKVAL field..
Thanks,
Bhupesh
Hi,
>> Now I want to check If CHKVAL is DK and then map SOAFF1-->DDNUM.
Firstly u cannot check the value of a target field. With Variables (7.1 and above) forst you will have to assign a value and then use it (but this will not be part of target str).
Best Solution:
Right click on segment 3 and click duplicate subtree. Do it twice to have three subtrees(since one is already present) each for DK,DX and DZ
Now for each of these subtrees map the values of DDNUM accordingly. And assign constants to CHKVAL for each subtrees as DK, DX and DZ respectively.
This should solve your issue.
Cheers,
Souvik
check this blog:
/people/stefan.grube/blog/2006/01/09/the-use-of-suppress-in-the-xi-30-graphical-mapping-tool
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You want to check value of Target field and then assign value to some other Target field .. ? you sure..
please explain your scenario..
Thanks,
Bhupesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Two options..
1. Use Local variable to store value of target field and use that target field in condition for other field mapping.. check SDN for how to use local variable
2. anyways first target field you are filling thru one of the source field or constant only.. so even you can use that also in your condition to map it accordingly..
second option is more easy in case you have first target field value coming from one of the source field then use that field in condition to map other field..its logical solution..
Thanks,
Bhupesh
User | Count |
---|---|
86 | |
10 | |
10 | |
9 | |
7 | |
7 | |
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.