Forum Discussion

BenvanBergen's avatar
BenvanBergen
Contributor
9 days ago
Solved

Data Import of prices with average result

Hello, In our planning solution I'm looking for a change to plan with less detail. We import transfer prices on material level, but now we want to plan on product level which includes several mat...
  • BenvanBergen's avatar
    3 days ago

    Solution we found with help of our consultant who gave some suggestions. We create a second data source, there we loaded value 1 for each combination with a different UD8. Then we created a business rule and added that to an existing Data Management step. The business rule divides the prices by the value.

    Like this:

    If args.CustomCalculateArgs.FunctionName.XFEqualsIgnoreCase("AssumptionSeedingTP") Then
    If ((Not api.Entity.HasChildren()) And (api.Cons.IsLocalCurrencyForEntity())) Then
     
    api.Data.Calculate("V#Periodic:O#Import:F#Calc:U1#110F:U5#None:U6#None:U7#None:U8#USD = V#Periodic:O#Import:F#ImportBW:U1#110F:U5#None:U6#None:U7#None:U8#USD / V#Periodic:O#Import:F#ImportBW:U1#110F:U5#None:U6#None:U7#None:U8#None","A#ICPrice, A#IC_MU",,,,,,,,,,,,,,True)
     
    End If
    End If
     
    Not an ideal solution, but seems not much additional effort.