Forum Discussion
There aren't many apis to look at stage data; there is FdxExecuteStageTargetTimePivot but it feels a bit overkill here. Most people will just go and query tables: open connection, sql etc. Doing it in transformation rules will likely be pretty slow though, even with caching hacks through globals. Besides, looking at stage data might mean you miss out on potentially important information loaded with forms, journals, or other workflows.
I'll be that guy: I don't think this sort of operation belongs to Derivative Rules at all. You're doing financial calculations that are better (and more easily) done in the cube. I would just load stuff in the original source currency, to dummy entities or even a separate dummy cube if necessary, then do all the financial manipulation later in regular rules.
Hey Jack, thank you for the honest feedback and I've now come to that realization myself.
My original intention was 100% cost allocation from one Entity/UD2 intersection to another Entity/UD2 intersection within certain UD3 hierarchies. This idea works exactly as intended, until you introduce Fx rates. Then this idea fails in the second month because as I pull Fx rates into a complex expression on the Derivative Rule, the system will translate the YTD values instead of just the Periodic, hence why I was trying to fetch the prior periods amount and derive the current month's activity to isolate the translation.
Anyways, I'll go down the route of allocations within the Cube.
Thanks again!