Getting data from Stage in Finance Business Rule
Hi there,
thankful for immense contribution from community that has made life easier as a system admin. Currently working on a requirement to query stage data for specific Entity, Account, Scenario, UD1 through UD5 and reseed it back to a intersection that got changed by user input to allow admin to revert any changes done by users. I tried using the below:
Dim criteria As New Text.StringBuilder
criteria.Append("U1T = '" & ud1_seeded & "' ")
criteria.Append("And U2T = '" & ud2_seeded & "' ")
criteria.Append("And U3T = '" & ud3_seeded & "' ")
criteria.Append("And U4T = '" & ud4_seeded & "' ")
criteria.Append("And U5T = '" & ud5_seeded & "' ")
Dim dValue As Decimal = api.Functions.GetStageBlendNumber("TestCube", "TestEntity", _
"TestScenario", "2024M1", "TestAccount", BlendCacheLevelTypes.Custom, "Test", _
"TestWorkflowProfileName", "U1T,U2T,U3T,U4T,U5T", criteria.ToString, "Amount", _
BlendNumericOperationTypes.FirstValue)
doesn't throw a error, but its not getting the amount seeded for TestAccount for the above mentioned workflow profile name. I checked the onestream function documentation, it says the following function documentation:
Dim dValue As Decimal = api.Functions.GetStageBlendNumber(cubeName, entityName, scenarioName, timeName, accountName, cacheLevel, cacheName, wfProfileName, fieldList, criteria, fieldToReturn, mathOperation)
Are my cacheLevel and cacheName correct i set cacheName as "Test" and cacheLevel as BlendCacheLevelTypes.Custom? any other inputs are appreciated