Forum Discussion

Nikpowar97's avatar
Nikpowar97
Contributor
4 months ago

Custom FX Translation Not working for Rate type Periodic

I am trying to run a Custom FX translation rule on run a set of Account @HistoricalRate with Periodic Rule type.
The function seems to be working fine for the direct Rule type but does not seems to be working for the periodic Rule type. any reason?

						
Dim Accts As List(Of MemberInfo) = api.Members.GetMembersUsingFilter(api.Dimensions.GetDim("Dim_Accounts").DimPk,"A#Equity.Base.Remove(A#CTA,A#CY_RE,A#Pr_Yr_RE)")

Dim AcctList As New List(Of String)
For Each Mem As MemberInfo In Accts
   AcctList.Add(Mem.Member.Name)
Next

If AcctList.Contains(api.Pov.Account.Name) Then
   Return New FXRateResult(False,api.FxRates.GetCalculatedFxRate(api.FxRates.GetFxRateType("HistoricalRate")),FXRuleType.Periodic)  'Does not work
  'Return New FXRateResult(False,api.FxRates.GetCalculatedFxRate(api.FxRates.GetFxRateType("HistoricalRate")),FXRuleType.Direct)  'This works (Commented)
End If

 

    • Nikpowar97's avatar
      Nikpowar97
      Contributor

      I expect at Rule type Periodic, the translated value = Prior period Translated value + YTD change from period period * Translation Rate. which does not seem to be working.

      however the for the Direct Rule type, the translated value = Current YTD Local value * Translation Rate . which works as expected.

      • KarlT's avatar
        KarlT
        Contributor III

        What kind of Rule Type do you have assigned to the cube/scenario? And is the Translation algorithm on the cube "Custom" or "Standard using Business Rules"?