Recent Discussions
Calculation Error "Error processing script: 'A#All = 0 * A#All"
I was running into issues clearing durable data prior to Clearing it so I calculated the data prior to the Clear statement so the data was "calculated", then ran the ClearCalculatedData stmt. It works fine for me, but I have admin access and it works fine for a select few users. But for the majority of users they receive the error "Error processing script: 'A#All = 0 * A#All". I can not easily test in Prod as my hands are tied as far as making security changes. In prod I have other users with the same set of security groups (just pointing to other entity WFs) and they do not receive the error. In our Dev environment I can set up a native user with the exact same security groups as a prod user that fails and I do not receive an error. As for it being an issue with data, I have an entity where 1 user can run it and another can not. And they have the same set of security groups. Does anyone have any thoughts on what is going on? I also thought that the ClearCalculatedData should have been able to clear it (durable data) with the Boolean set to true, but it doesn't. Does anyone have any thought on why the clear does not work w/o calculating the data prior to clearing it? I did see a note about the ClearCalculatedData that the final argument must be true to clkear any data with a storage type Durable. But I'm not exactly sure what this means - can someone clarify that statement for me? This is the code: This is the error:jzachar2 days agoNew Contributor1.8KViews0likes6CommentsIssue Loading multiple CSV files into custom table using LoadCustomTableUsingDelimitedFile
Hello Fellow OneStream team - I have multiple csv file in a file share folder, using BRApi.Utilities.LoadCustomTableUsingDelimitedFile to do the job, but it's loading only single csv file into the custom table. Below is extender BR , not sure what am I missing in the For loop, guidance is appreciated. Namespace OneStream.BusinessRule.Extender.Load_Table_Data Public Class MainClass Public Function Main(ByVal si As SessionInfo, ByVal globals As BRGlobals, ByVal api As Object, ByVal args As ExtenderArgs) As Object Try Select Case args.FunctionType Case Is = ExtenderFunctionType.Unknown 'Select Load options Dim loadMethod As String = "Replace" '<-- Select file load method (Replace, Merge) Dim dbLocation As String = "App" '<-- Specify db type Dim tableName As String = "XFC_OStoSF_BudgetData" '<-- Specify table name to load Dim blnSkipHeader As Boolean = True '<-- Specify if the first row should be skipped (True/False) Dim configSettings As AppServerConfigSettings = AppServerConfig.GetSettings(si) 'Note: file path must be accessible from all application servers Dim xfolderPath As String = FileShareFolderHelper.GetDataManagementExportUsernameFolderForApp(si,True, configsettings.fileShareRootFolder,si.AppToken.AppName) & "\20251014" ' Dim filesToLoad As String = "*_CubeData.csv" Dim fileList = System.IO.Directory.GetFiles(xfolderPath, filesToLoad) ' 'Get list of files to copy For Each file As String In fileList 'Get the file name Dim fileName As String = file.Substring(xfolderPath.Length + 1) BRApi.ErrorLog.LogMessage(si, "FileName:" & fileName) ' Dim fileList = System.IO.Directory.GetFiles() For Each fName As String In fileName 'Define columns that are in the table (this must match the fields in the deminted file) 'Update the fields with the column names/types to match the table being loaded Dim fieldTokens As New List(Of String) fieldTokens.Add("xfText#:[Cube]") fieldTokens.Add("xfText#:[Entity]::NewGuid") fieldTokens.Add("xfText#:[Parent]") fieldTokens.Add("xfText#:[Cons]") fieldTokens.Add("xfText#:[Scenario]") fieldTokens.Add("xfText#:[Time]") fieldTokens.Add("xfText#:[View]") fieldTokens.Add("xfText#:[Account]") fieldTokens.Add("xfText#:[Flow]") fieldTokens.Add("xfText#:[Origin]") fieldTokens.Add("xfText#:[IC]") fieldTokens.Add("xfText#:[UD1]") fieldTokens.Add("xfText#:[UD2]") fieldTokens.Add("xfText#:[UD3]") fieldTokens.Add("xfText#:[UD4]") fieldTokens.Add("xfText#:[UD5]") fieldTokens.Add("xfText#:[UD6]") fieldTokens.Add("xfText#:[UD7]") fieldTokens.Add("xfText#:[UD8]") fieldTokens.Add("xfDec#:[Amount]") fieldTokens.Add("xfText#:[HasData]") fieldTokens.Add("xfText#:[Annotation]") fieldTokens.Add("xfText#:[Assumptions]") fieldTokens.Add("xfText#:[AuditComment]") fieldTokens.Add("xfText#:[Footnote]") fieldTokens.Add("xfText#:[VarianceExplanation]") 'Execute file load ' BRApi.Utilities.LoadCustomTableUsingDelimitedFile(si, SourceDataOriginTypes.FromFileShare, filePath & fileName, Nothing, ",", dbLocation, tableName, loadMethod, fieldTokens, blnSkipHeader) BRApi.Utilities.LoadCustomTableUsingDelimitedFile(si, SourceDataOriginTypes.FromFileShare, xfolderPath & "\" & fileName , Nothing, ",", dbLocation, tableName, loadMethod, fieldTokens, blnSkipHeader) Next Next End Select Return Nothing Catch ex As Exception Throw ErrorHandler.LogWrite(si, New XFException(si, ex)) End Try End Function End Class End Namespacefellow_Ones4 days agoNew Contributor III29Views0likes2CommentsDatabuffer not working in an WS Assembly rule but is working in a Business Rule
Hi, I ran into an issue that a data buffer rule does not work in a workspace assembly but does work in the Business Rules area. The data buffer rule is the one found in this forum topic and is relatively simple. See link. Question: Is there an option to clear non-calculated data in a “bulk” (as known from hs.clear) other than looping through the data buffer and use “SetDataCell” (which has a higher performance impact)? The “ClearCalculatedData“ is not impacting input/imported data – right? | OneStream Community I have this rule in an existing custom calculate rule in the assembly and the rule fails to get the source data buffer. I take this same rule and include it in a new Business Rule and it runs fine. Rules that work in the business rules should work in assemblies also.SolvedMontreux5 days agoNew Contributor III39Views0likes2CommentsConnector BR fails to execute successfully
Hello Team, I am currently writing a connector business rule that connects an EDM system to retrieve a file, apply mapping logic, and process the resulting DataTable into ACM. I have successfully implemented the same integration code for several other connectors, all of which are functioning as intended. However, when I attempt to apply the same logic for the Account connector, I encounter the following error: "Index was out of range. Must be non-negative and less than the size of the collection. (Parameter 'index')" I have rewritten the rule twice but have not been able to resolve the issue. Do you have any insights into why this might be occurring?Solvedddgonzalez5 days agoOneStream Employee40Views0likes3CommentsMonthly vs Quarterly allocation of accounts
Hello, We are trying to automate a simple allocation of specific corporate expense accounts. The accounts allocate to different business based on their contribution to total GP. I currently have two calculations: Account Dynamic Calc - BU GP / Total GP, giving the business GP% UD8 Dynamic Calc - GP% * Corporate Expense Account, giving the expense to be allocated to each BU I run into an issue when data is pulled as either QTD or YTD. As an example, if someone is to pull the data at 2025M3/QTD, it will calculate calculate a separate GP% for the QTD information and complete the calculation. This creates a discrepancy when looking at data monthly vs. quarterly. Instead, I would need it to add together months 1-3 for consistency. (See below table for reference) Is there a way to make a dynamic calculation calculate only at the monthly level and instead aggregate months for other view selections (QTD/YTD)? What is happening What I need Calculation QTD GP * QTD GP% M1 + M2 + M3 MTD M1 M2 M3 Q1 / M3 QTD Q1 / M3 QTD Business GP 100,000 400,000 200,000 700,000 700,000 Total GP 500,000 1,000,000 900,000 2,400,000 4,300,000 GP % 20.0% 40.0% 22.2% 29.2% Corporate Expense 10,000 50,000 20,000 80,000 Allocation 2,000 20,000 4,444 23,333 (29.2% * 80,000) 26,444 (M1 + M2 + M3)emclend10 days agoNew Contributor II30Views0likes1CommentVary description vy user culture in XFBR
Hello, We are facing the following issue, we use the following xfbr to generate accounts in a cubeview rows and retrieve descriptions : XFBR(CCF_XFBR, GetCCFDrillDownWithDescription2,memberExp=[A#CashFlow_Gestion.TreeDescendantsInclusive], Time=|CVTime|). However, the Cube View where this XFBR is applied always displays the descriptions in the default format. The description does not adapt based on the user’s culture settings. How can we make the XFBR return descriptions that vary according to the user culture? For reference, here is the XFBR code : Public Function GetCCFDrillDownWithDescription2(ByVal si As SessionInfo, ByVal globals As BRGlobals, ByVal api As Object, ByVal args As DashboardStringFunctionArgs) As String Try 'Get the Dim PK for Entity Dimension Dim accountDimPk As DimPk = BRApi.Finance.Dim.GetDimPk(si,args.SubstVarSourceInfo.WFAccountDim) Dim flowDimPk As DimPk = BRApi.Finance.Dim.GetDimPk(si,args.SubstVarSourceInfo.WFFlowDim) 'Dim memberListClass As New OneStream.BusinessRule.Finance.CCF_FinanceLogics.MainClass Dim memFilterAccounts As List(Of MemberInfo) = BRAPi.Finance.Members.GetMembersUsingFilter(si, accountDimPk, args.NameValuePairs("memberExp"), True) If memFilterAccounts.Count = 0 Then ' brapi.ErrorLog.LogMessage(si,"Cash flow Account Member Not found in CubeView member filter. Check XFBR syntax (GetCCFDrillDown) in Cube view") Return "A#None:F#None:Name(Please check memberfilter in cubeview. Cashflow Account not found)" End If 'Use a text builder to build a string Dim resultString As New Text.Stringbuilder() Dim isfirstItem As Boolean = True ' Dim accountFlowComb As String ' Dim flowBaseMembers As List(Of Member) Dim objDataCellInfoUsingMemberScript As New DataCellInfoUsingMemberScript Dim tftEntityID As Integer = Brapi.Finance.Members.GetMemberId(si,dimTypeId.Entity, "CF") Dim objScenarioType As ScenarioType = BRApi.Finance.Scenario.GetScenarioType(si, args.SubstVarSourceInfo.WFScenario.MemberId) Dim timeReference As String = BRApi.Finance.Entity.Text(si, tftEntityID, 1, objScenarioType.Id, args.SubstVarSourceInfo.WFTime.MemberId) Dim MatrixTime As String = args.NameValuePairs("Time") Dim scenarioReference As String = BRApi.Finance.Entity.Text(si, tftEntityID, 2, objScenarioType.Id, args.SubstVarSourceInfo.WFTime.MemberId) If scenarioReference = String.Empty Then scenarioReference = args.SubstVarSourceInfo.WFScenario.Name Dim cashFlowSettings As DataTable = BRApi.Import.Data.FdxExecuteDataUnit(si, "PARAM_CF", "E#CF", "Local", objScenarioType.Id,"S#" & scenarioReference, "T#" & MatrixTime, "YTD", True, "Amount <> 0", 4, False) 'Dim cashFlowAdj As DataTable = BRApi.Import.Data.FdxExecuteDataUnit(si, "CONSO", "E#CF", "Local", objScenarioType.Id,"S#REEL","T#" & timeReference , "YTD", True, "Amount <> 0", 4, False) 'Exit Function Dim CFSiN As Boolean = cashFlowSettings Is Nothing If cashFlowSettings Is Nothing Then Brapi.ErrorLog.LogMessage(si,"No CashFlow setting found") Return "" 'Exit Function ElseIf cashFlowSettings.Rows.Count = 0 Then Brapi.ErrorLog.LogMessage(si,"No CashFlow setting found") Return "" 'Exit Function End If Dim space As String = String.Empty Dim sign As String = String.Empty Dim AccountDescription As String ' Dim AccountDescription2 As String For Each account As MemberInfo In memFilterAccounts ' brapi.ErrorLog.LogMessage(si,"account " & account.NameAndDescription) space = " " For i = 0 To account.IndentLevel space = space & " " Next 'Exit Function resultString.Append("A#" & account.Member.Name & ":Name(" & space & account.Member.NameAndDescription & "):F#None,") 'resultString.Append("A#" & account.Member.Name & ":Name(" & space & account.Member.NameAndDescription & "):F#None:U7#MT_RETTFT,") ' Cb#CONSO:E#EIMER:P#?:C#Local:S#REEL:T#2022M12:V#YTD:A#RD_T110:F#None:O#Top:I#Top:U1#None:U2#None:U3#Top:U4#None:U5#None:U6#None:U7#MT_RETTFT:U8#CF_CalcAmount 'Ajout des ecritures Dim memberFilter As String = "MT_RETTFT" Dim UD7Desc As String = BRApi.Finance.Metadata.GetMember(si, dimTypeId.UD7,memberFilter).Description 'ResultString.Append("A#" & account.Member.Name & ":Name(" & space & account.Member.NameAndDescription & "):F#None:U7#MT_RETTFT:Name(" & UD7Desc & "),") If Not BRApi.Finance.Members.HasChildren(si, accountDimPk, account.Member.MemberId) Then Dim cashFlowSettingRows() As DataRow = cashFlowSettings.Select("UD7 = '" & account.Member.Name & "' AND UD8 = 'None'") For Each row As DataRow In cashFlowSettingRows AccountDescription = BRApi.Finance.Metadata.GetMember(si, dimTypeId.Account,row("Account")).NameAndDescription If row("Amount") = -1 Then sign = "(-)" 'ResultString.Append("A#" & row("Account") & ":Name( "& space & " " & AccountDescription & "):F#" & row("Flow") & ":U7#" & account.Member.Name &",") 'ResultString.Append("A#" & row("Account") & ":Name( "& space & " " & AccountDescription & "):F#" & row("Flow") & ":U7#" & row("UD7") &",") ResultString.Append("A#" & row("Account") & ":Name( "& sign & space & AccountDescription & "):F#" & row("Flow") & ":U7#" & row("UD7") &",") Next ResultString.Append("A#" & account.Member.Name & ":Name( " & space & account.Member.Name & space & UD7Desc & "):F#None:U7#MT_RETTFT:U8#None" &",") 'ResultString.Append("A#" & account.Member.Name & ":Name(" & space & account.Member.NameAndDescription & "):F#None:U7#MT_RETTFT:Name(" & UD7Desc & "),") End If Next Return resultString.ToString Catch ex As Exception Throw ErrorHandler.LogWrite(si, New XFException(si, ex)) End Try End FunctionSolvedHatim_Elhaouma10 days agoNew Contributor II72Views0likes4CommentsWhile consolidating on Top level getting error in Stored Calc
HI Team, We have created a stored calc and it is working fine at Base and parent entity level, but when we are running at Top entity level and my Time is 2028, at this i am getting below error. could not able to figure it. Can you please help us resolve the issue.ShivaPrasad10 days agoNew Contributor III27Views0likes2CommentsFreeze Option in Dashboard
Hi Team, I have created a dashboard with Vertical Stake Panel option and attached multiple Cube view components. when i scroll left to right in the dashboard my CV row headers are scrolling. how to freeze them in the dashboard.ShivaPrasad12 days agoNew Contributor III22Views0likes1CommentUD8 Dynamic rule to hide derived values. Does anyone have an example of this UD8 calc?
•You can set a text color on the Cubeview (i.e black) so all values show in a single colour, which would override the default grey/black. •You can also use a UD8 dynamic rule to hide derived values in future periods, if necessary.Ando12 days agoNew Contributor II3.3KViews0likes7CommentsTransformation Rule - Split - Complex Expression
I need to get, from a Custom Dimension, the characters starting after "D." or "T." when it's possible. Normally it comes as D. or T. at the beginning, followed by XYZ. What I want to get, as a direct mapping, is XYZ (these are the members created in the Custom Dimension in OneStream). What type of mapping can I use for this? I don’t want to trim the source member in the Data Source because I need the full original source member to appear in Stage.Solvede_poveda16 days agoNew Contributor III38Views0likes3Comments