cancel
Showing results for 
Search instead for 
Did you mean: 

PI mapping issue

Former Member
0 Kudos

Hi ,

my mapping source and target field:

Source

E1KNB1M-ZSABE or E1KNVKM-ANRED + E1KNVKM-NAMEV + E1KNVKM-NAME1

Target : Contact

i am not able to make mapping logic.it throws exception

Please note:Contact information u2013 should be truncated to 30 characters

if using E1KNVKM and information is too long.

Please confirm in which order i use functions.

regards

Mohit

Accepted Solutions (1)

Accepted Solutions (1)

former_member200962
Active Contributor
0 Kudos
Please note:Contact information u2013 should be truncated to 30 characters

use substring function (0,29)

Former Member
0 Kudos

Hi Abhisek,

can you please explain function sequence.for Ex

Field 1

OR operater

field 2

concate

field 3

concate

field 4

former_member200962
Active Contributor
0 Kudos
E1KNB1M-ZSABE or E1KNVKM-ANRED + E1KNVKM-NAMEV + E1KNVKM-NAME1

If this is your requirement (to concat the IDOC-values) and due to this you are getting the error....then better high-light it to the functional team and tell them the consequence (length issue) before you implement any truncation on it.

Former Member
0 Kudos

Hi Abhisekh,

if i use this:

E1KNB1M-ZSABE or E1KNVKM-ANRED + E1KNVKM-NAMEV

then please tell how to use.

former_member200962
Active Contributor
0 Kudos

concat all the fields first and then implement the substring function to have the value limited to 30 characters (as high-lighted by the error)

Former Member
0 Kudos

Imho, you can do faster by using an UDF....

Former Member
0 Kudos

Hi Abhishek,

u have noted after first field OR operator is to be used.

we need to selct output from fist field OR concatenating last 3 field.

regards

Mohit

Former Member
0 Kudos

Hi Mohit,

Perform the condition check and do the below:

Is there any field length restriction, if so then it would be easy to achieve.

Else

Follow what Abhishek said : concat the field values and do the substring to trucate.

Thanks,

former_member200962
Active Contributor
0 Kudos
u have noted after first field OR operator is to be used.

I did not note any such thing....the or that you see in my reply is actually from your first post

we need to selct output from fist field OR concatenating last 3 field.

then you have to implement condition on it.....no one from SDN can predict what that condition should be....you will have ask it to the person who assigned the mapping to you.

baskar_gopalakrishnan2
Active Contributor
0 Kudos

>>> we need to selct output from fist field OR concatenating last 3 field

If the above is the condition for the mapping, do the following

check whether values exist in first field if so, pass the first 30 characters of the first field value to target

use exist function and if that is true use substring(0,29) and map to the target.

or

check whether values exist in the three fields ... and concat all the three fields

Use concat function for three fields followed by substring(0,29) and map it to target field.

Answers (1)

Answers (1)

Former Member
0 Kudos

So you want to map either of the values to your target.

I mean either E1KNB1M-ZSABE or E1KNVKM-ANRED + E1KNVKM-NAMEV + E1KNVKM-NAME1

You also mentioned that the length should not exceed 30 characters. So you can do your mapping lke this...

IF E1KNVKM Not empty then substring (0, 29) else map E1KNVKM-ANRED + E1KNVKM-NAMEV + E1KNVKM-NAME1 to target.

So this means you have to use "IfElse" function along with "equalS", "NOT", "Constant" and "Substring" function. I hope you can arrange these function as per your need.