2011 Nov 16 3:23 PM
Hi FM Experts,
I have a problem related with the derivation strategy.
When create sales order (order type: replacement order), it will consumed the budget.
I already assigned the derivation with function module FMDT_READ_MD_ORDER_SD_ITEM and for the target fields which is sales document item category filled with USERTEMP1. Then create derivation rule USERTEMP1 (filled with SO item type) to funds center.
The assignment in item level of SO is working. But, if I create normal sales order, the assignment follow with the assignment before.
How to differentiate the assignment automatically during SO creation between replacement order and normal sales order?
Many thanks.
2011 Nov 17 8:02 PM
Hello,
It takes 3 derivations to play the trick:
1. Creat a derivation using function module FMDT_READ_MD_ORDER_SD_HEADER. Assign target field USERTEMP1 to AUART (Sales document type)
2. Create derivation with Initialization. Initialize USERTEMP1 and specify condition as USERTEMP1 not= xyz (xyz is the order type for replacement order)
3. Create a derivation using function module FMDT_READ_MD_ORDER_SD_ITEM. Target field assignment is the same as what you did except you need to specify the feature as 'Overwrite with new value'. You also need to specify condition as USERTEMP1 = xyz (xyz is the order type for replacement order).
The 3 rules in the above sequence should be able to accomplish your goal of skipping non-replacement orders.
Regards,
Ming
2011 Nov 17 8:02 PM
Hello,
It takes 3 derivations to play the trick:
1. Creat a derivation using function module FMDT_READ_MD_ORDER_SD_HEADER. Assign target field USERTEMP1 to AUART (Sales document type)
2. Create derivation with Initialization. Initialize USERTEMP1 and specify condition as USERTEMP1 not= xyz (xyz is the order type for replacement order)
3. Create a derivation using function module FMDT_READ_MD_ORDER_SD_ITEM. Target field assignment is the same as what you did except you need to specify the feature as 'Overwrite with new value'. You also need to specify condition as USERTEMP1 = xyz (xyz is the order type for replacement order).
The 3 rules in the above sequence should be able to accomplish your goal of skipping non-replacement orders.
Regards,
Ming
2011 Nov 18 2:01 AM
Hai, Ming.
Thanks for your answer.
I already did the step you mentioned. But it didnt worked.
After I created the function module like step (1), I create derivation rule Sales doc type to Funds center. And I do it for the step (3). Does the function module conflict?
Both sales order and replacement order didn't derive the funds center and commitment item automatically.
Many thanks.
Edited by: rosi88 on Nov 18, 2011 3:50 AM
2011 Nov 18 4:25 PM
Hi,
Maybe you can clarify on what you really trying to accomplish. For your replacement order, how do you want to derive the funds center (from order type or item category)? For your non-replacement order, how do you want to derive the funds center (from order type or item category)?
From your second message, I guessed what you wanted is FC from item Category for replacement order and FC from Order Type for non-replacement order. If this is true, all you need is 5 rules:
1. derive Order Type using FMDT_READ_MD_ORDER_SD_HEADER;
2. derive FC from Order Type if Order Type is non-replacement order (you specify that in the rule condition);
3. initialize USERTEMP1 if Order Type is non-replacement order (you specify that in rule condition);
4. derive item category using FMDT_READ_MD_ORDER_SD_ITEM if Oder Type is replacement order (you specify it in rule condition);
5 derivation FC from Item Category if Order Type is replacement order (you specify it in rule condition).
You will need to Always specyfy 'Overwrite with new value' for target fields.
They worked like a charm when I tested the scenario in my system.
Regards,
Ming
2011 Nov 21 7:41 AM
Thanks,Ming.
I already create the derivation as your directions. And it worked.