cancel
Showing results for 
Search instead for 
Did you mean: 

Assign the attribute value of a characteristics to another characteristics

Former Member
0 Kudos

I need to assign one attribute value to another charcteristics in the transformation. For example, I have a chacteristics 0customer. 0customer has an attribute called OEM. I need to assign OEM value to another characteristics called ZOEM in the transformation of my backlog cube. Can anyone provide me some insight on how to do this?

TIA

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Sharon,

This is simple. However, you need to have the same infoobject in your cube as well.

In your example, OEM is attribute of 0customer and in order to read the value of the OEM and write it in the cube you need to have infobject OEM in your cube as well.

You need to have the 0CUSTOMER infoobject in your source and target. Map them directly.

Now map 0CUSTOMER -> OEM and in the rule details select rule type as "Read Master Data" and in the "From Attrib. of" give the infoobject from which you want to read the master data. it's 0CUSTOMER in your case.

Regards,

Sudheer.

Edited by: Sudheer Kumar Kurra on Jan 22, 2011 8:40 AM

Former Member
0 Kudos

Thanks much, Sudheer. It worked very well.

However, what if I have a logic need to apply? So he is the psudo code:

if 0CUSTOMER->ZOEM is NOT initial then ZOEM = 0CUSTOMER->ZOEM.

otherwise ZOEM=ZODM ( ZODM is one of the charateristic field that is already in the cube)

Sharon

Former Member
0 Kudos

Hello Sharon

In this case you have to use a routine.

You can use select in the table of attributes of an infoobject.

For example for the infoobject 0CUSTOMER the table of attributes is /BI0/PCUSTOMER.

Choose routine in your transformation e do something like this:


Data V_ZOEM TYPE /BI0/PCUSTOMER-ZOEM.

Select single ZOEM
From /BI0/PCUSTOMER
into V_ZOEM
Where CUSTOMER = SOURCE_FIELDS-CUSTOMER
AND   OBJVERS = 'A'.

If V_ZOEM IS NOT INITIAL.
     RESULT = V_ZOEM.
ELSE.
    RESULT = ZODM.
END IF.

For this code work properly, you to mapped CUSTOMER and ZODM for your infoobject ZOEM.

I hope that this will help you

Kind regards,

Paulo

Answers (0)