Hello all
I have tried a number of ways and I am not able to calculate the length of the incoming field in transformation file for my data load. Here is the issue.
I have an incoming string of length 10 and I need to use it to update multiple dimensions which will need first 2, 4 ,6 , 8 characters respectively.
Now in transformation file ID=ID(1:2) works perfect. However, the BW InfoObject will have multiple values as shown below:
ID | Description |
---|---|
AB | Business |
ABCD | Business Organization |
ABCDEF | Business Line |
ABCDEFGH | Product Family |
ABCDEFGHIJ | Product Line |
ABCDEFGHIJKL | Brand |
I want to update my dimension for Business Organization. I need to update only the records where the length of the incoming string is 4. If I do ID(1:4), I will get the duplicate records and will see the ID less than 4 characters in rejected records. The latter is not such a big issue but the former one is as I need to fetch the right description as well. The formula should check the length and then only pass the record else a dummy value.
A formula to achieve this in the transformation file is what I am looking for.
Regards
Gajendra