cancel
Showing results for 
Search instead for 
Did you mean: 

Mapping Problem

Former Member
0 Kudos

Hi Friends,

I am working on WP_PLU Idoc, i got struck with one mapping issue.

In my article master , line items text description is available in one segment which repeats twice for each article.

based on the logic

if qualifiertxt = LTXT then i have to pick the description

if qualifiertxt= 02 then i have to pick and copy the same to sales description

when i map based on condition one line item will work fine.

the problem, if i have more no of line items..

in second line item , i am not getting first description .But i am gettingsalesdescriiption.

Can any suggest on this..

Regards,

Vijay

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Vijay,

for more no of line items you should use "UseOneAsMany" function for the line item description.

reply if you need more help.

**Reward points if helpful.

--Sankar Choudhury

Former Member
0 Kudos

Hi,

Thanks for all your inputs. If i use copy value function i will get the repeated text description for all the line items...

It should work as per input description for each line item

In idoc the same segment is repeating twice,

with two values..

First segment it is coming like ..

If qualifier text = LTXT t

value. ..... pick

during display queue..my output is

first two values are populating followed by two suppress values..then values, again suppress..

Second segment with same name..

if qualifier text = 02

value . ..... pick

I have to map to two target desctiptons

here both the descriptions are same

..

description

sales descripti

..

Hope i am clear..

Any suggestions please..

Regards,

Vijay

justin_santhanam
Active Contributor
0 Kudos

Vijay,

Good Morning! Could you give us the source and target structure with the occurrences. For source structure don't give the entire strucute, just give the segment which contains the Description. It will be easy for us to suggest.

raj.

Former Member
0 Kudos

Hi,

Here you are getting same description in each line item, so by using copyValue() it just coping your first line item descand sinc two desc are same it seems like taking the 2nd line item desc, but the problem will occur when the description will be different so i suggest you to use "UseOneAsMany", it will copy the desc from each line item(no matter the desc are same or different).

**Let me know if any issue with it...

--Sankar Choudhury

Former Member
0 Kudos

hi,

you can try with If condition.

regards,

arijit

Former Member
0 Kudos

Hi Raj,

Source Structure:

E1WPA03 .....0.99

QUALARTXT.....0.1

TEXT ....0.1

Target structure:

description 0.1

salesdescripton 0.1

I am not able to copy the content on forum, Can you tell me how to copy in sdn forum so that you will have clear idea..

Regards,

vijay

Former Member
0 Kudos

Hi,

if you are getting in output display queue first two values are populating followed by two suppress values..then values, again suppress.

then, just add the following functions in the target mapping of sales description...

->removeContexts>splitByValue[EachValue]-->SalesDescription

by it you can get two descriptions in target.

*Reward points if helpful.

--Sankar Choudhury

justin_santhanam
Active Contributor
0 Kudos

Vijay,

Could you give us the target root node occurrence and sample data on how you need.

raj.

Former Member
0 Kudos

Hi Raj,

I would like to send screen shot , so that it would be easy to understand the problem.

If you dont mine , can i have your Id..so that i will send screenshot.

Regards,

Vijay

justin_santhanam
Active Contributor
0 Kudos

Vijay,

You can get it from Business Card.

Did you got the ID?

raj.

Edited by: Raj on Apr 1, 2008 9:23 AM

Former Member
0 Kudos

Hi All,

Thanks for all your inputs, Problem is fixed.

With contexts it worked for me..

Once again thanks to one and All.

Regards,

Vijay

justin_santhanam
Active Contributor
0 Kudos

Cool. Have Fun!

raj.

Former Member
0 Kudos

Hi,

Have u applied Context change in mapping

/people/riyaz.sayyad/blog/2006/04/23/introduction-to-context-handling-in-message-mapping

Regards

Seshagiri

Edited by: N V Seshagiri on Apr 1, 2008 1:04 PM

Former Member
0 Kudos

Hi,

use copyValue function for line item.

reward points if helpful.

regards,

arijit