Business Rules for new OS implementation
Hi, we are implementing OS at present, and this is our first-ever project in OneStream; I need guidance on Business Rules. I am not sure what business rules we need to consider after and before we import the data from the Client system to match the client's legacy system data with OneStream numbers. Thanks, Preeti37Views0likes2Commentsperformance issue.
Hello OneStream Community, I am working with a Cube View where I need to display the Income Statement data for the end of every year (December). The data should show up as the beginning balance for the January month in the subsequent year. To achieve this, I used a Row Override1 member filter with the formula T#povprioryearm12. The Cube View includes four dimensions: Entity, Division, Cost Center, and Accounts. However, I am experiencing slow loading times when the view is being accessed. it is not exporting to Excel to validate. I would like to know if there are any best practices or strategies for improving the performance of the Cube View in this scenario. Are there specific optimizations I should consider for the member filter, the dimensions, or the Cube View configuration to reduce loading times? Any advice or recommendations would be greatly appreciated! Thank you in advance!18Views0likes1CommentMember Filter Functions in Finance BR
Is it possible to use Member Expansion functions like U1#[Top].Base.Where , U1#[Top].Base.Options within api.Data.GetDataBufferUsingFormula? I want to get data to the buffer from a Scenario / Scenario Type which is setup with a Summary UD1 dimension in the Cube Configuration.The data is loaded to this Scenario at Summary UD1 members. In the Spreadsheet I am able to pull the data using below member filter function. U1#[XX].Base.Options(cube = AA , ScenarioType = Operational) However when I apply the same function in the api.Data.GetDataBufferUsingFormula , I am getting errors stating need a comma after Options. If this function cannot be used within Finance BR is there another way to get the data from base members of Summary UD1 dimension? Dimension Summary UD1 Detail UD1 Members Summary UD1 Top CC001 Detail UD1 Top CC001 CC001145Views0likes3CommentsIsDurableCalculatedData
What is the default state of IsDurableCalculatedData if left out of an api.data.calculate statement? I'm assuming it's false but I just want to double check. I'm seeing an api.data.calculate statement which contains an "onEval" statement, then a comma, then False. If I look at Intellisense, the first field after the "onEval" is userState, followed by the Boolean for IsDurableCalculatedData. How should I read this statement? Is the False referring to the userState or to the IsDurableCalculatedData Boolean? Thanks, BobSolved22Views0likes3CommentsUse api.Data.Calculate to move data between 2 cubes
Is it possible to copy a value from one cube to another mutually exclusive cube with a Custom Calculate business rule? I am trying to copy a value from the Cb#Financial cube to the Cb#CASH cube. However, using the “api.Data.Calculate” code below I get the error “Invalid destination data unit in script” even though the Data Unit defined in my Data Management step matches the target cube Data Unit. Dim sTops As String = ":C#Local:S#AOP_Final:V#Periodic:A#BGMOPEX:F#EndBal_Input:O#BeforeAdj:I#None:U1#TopUD1:U2#TopUD2:U3#SALARY:U4#TopUD4:U5#TopUD5:U6#TopUD6:U7#None:U8#GC_USD" Dim sNones As String = ":Cb#CASH:E#US01:S#CashForecast_Forecast:T#2024M10:C#Local:V#Periodic:F#EndBal_Input:O#Forms:I#None:U1#None:U2#None:U3#NoVendor:U4#None:U5#None:U6#CashForecast_Plan:U7#None:U8#GC_USD" Dim dPayroll As Decimal = api.Data.GetDataCell("Cb#Financial:E#US01" & sTops & ")").CellAmount api.Data.Calculate("A#PAYUSA" & sNones & " = RemoveZeros(" & dPayroll & ")",True) In the past I have used the “BRApi.Finance.Data.SetDataCellsUsingMemberScript(si, objMemberScriptValues)” method and the “DM Data Export / Import” method to move data between cubes, but I was hoping that I could use a simple api.Data.Calculate utilizing the “Cb#” filter. Is this possible? Thanks.Solved40Views0likes1CommentUsing Conditional Input to Suppress CV Columns
Hi All, As the name states above I'm trying to dynamically modify suppression settings on a column in a CV based on a value selected in a parameter. So for example let's say if a user selects an option from a parameter I want to modify suppression settings on certain columns based on that selection choice. I have two questions: Is there a way to do this? If there is a way, how would this business rule/function be passed? In the CV? In the Cube? Thank You...Any assistance on this would be extremely helpful.Solved32Views0likes2CommentsHow to Exclude Entities from Confirmation Rule
Hello, I'm somewhat new to writing code for confirmation rules. I'm trying to create a confirmation that is only for 1 entity and we'd like it in our general rule groups for confirmation rules and not have to create it's own rule profile. Basically we need to the rule to be If WFProfile Entity <> 02140 return True, if not then (enter rule I already created). I couldn't find anything in the documentation about making it entity specific and excluding other entities. Thanks, WillSolved49Views0likes6CommentsCalculation 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:1.7KViews0likes5CommentsRecurring journal with Auto Post
So im trying to create a rule that pulls selected journals forward than posts them automaticaly. I have my test journal pulling forward as expected but when im trying to post the journal in rule below its causing the rule to error. The line in question is, BRApi.Journals.Process.ExecutePost(si, journalObjectHeader.UniqueID) What am i missing it seems pretty straight forward? Imports System Imports System.Data Imports System.Data.Common Imports System.IO Imports System.Collections.Generic Imports System.Globalization Imports System.Linq Imports Microsoft.VisualBasic Imports System.Windows.Forms Imports OneStream.Shared.Common Imports OneStream.Shared.Wcf Imports OneStream.Shared.Engine Imports OneStream.Shared.Database Imports OneStream.Stage.Engine Imports OneStream.Stage.Database Imports OneStream.Finance.Engine Imports OneStream.Finance.Database Imports System.IO.Compression Namespace OneStream.BusinessRule.Extender.CA_JournalRecurring2 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 CopyJournal(si) Case Is = ExtenderFunctionType.ExecuteDataMgmtBusinessRuleStep Case Is = ExtenderFunctionType.ExecuteExternalDimensionSource 'Add External Members Dim externalMembers As New List(Of NameValuePair) externalMembers.Add(New NameValuePair("YourMember1Name","YourMember1Value")) externalMembers.Add(New NameValuePair("YourMember2Name","YourMember2Value")) Return externalMembers End Select Return Nothing Catch ex As Exception Throw ErrorHandler.LogWrite(si, New XFException(si, ex)) End Try End Function Private Sub CopyJournal(ByVal si As SessionInfo) Try 'retrieve the names of the workflow parameters and concatenate them together Dim profilePostfix As String = brapi.Workflow.Metadata.GetProfile(si,si.WorkflowClusterPk.ProfileKey).Name Dim scenarioPostfix As String = brapi.Finance.Members.GetMemberName(si,dimtype.Scenario.Id, si.WorkflowClusterPk.ScenarioKey) Dim timePostfix As String = brapi.Finance.Members.GetMemberName(si, dimtype.Time.Id, si.WorkflowClusterPk.TimeKey) Dim strPostfix As String = $"{profilePostfix}_{scenarioPostfix}_{timePostfix}" 'The name of the journal to copy Dim journalName As String ="Tax Accruals_Houston.journals_Actual_2011M2" Dim oldJournalObject As JournalEx = BRApi.Journals.Metadata.GetJournalOrTemplate(si, journalName) brapi.ErrorLog.LogMessage(si, journalName) 'Remove the postfix from the old journal name to get the name Dim strOldName As String = oldJournalObject.Header.Header.Name Dim oldProfileName As String = brapi.Workflow.Metadata.GetProfile(si,oldJournalObject.Header.Header.WorkflowProfileID).Name strOldName = strOldName.Remove(strOldName.IndexOf(oldProfileName)) brapi.ErrorLog.LogMessage(si, strOldName) 'create a copy of the journal header Dim journalObjectHeader As New JournalHeader(oldJournalObject.Header.Header) 'Update the required parameters journalObjectHeader.Name = $"RF_{strOldName}{strPostfix}" journalObjectHeader.Description = $"Roll Forward from {oldJournalObject.Header.Header.name}: {oldJournalObject.Header.Header.Description}" journalObjectHeader.UniqueID = Guid.NewGuid() journalObjectHeader.MemberIds.Scenario = si.WorkflowClusterPk.ScenarioKey journalObjectHeader.MemberIds.Time = si.WorkflowClusterPk.TimeKey journalObjectHeader.WorkflowProfileID = si.WorkflowClusterPk.ProfileKey ' Log the unique ID Of the journal before posting brapi.ErrorLog.LogMessage(si, $"Journal UniqueID: {journalObjectHeader.UniqueID}") 'Journal status as working journalObjectHeader.JournalStatus = JournalStatus.Working 'Create a copy of the journal line item using linq Dim journalObjectLineItems As list(Of JournalLineItem) = oldJournalObject.LineItems.Select(Function(x) New JournalLineItem(x.LineItem)).tolist 'Create a new journal object Dim journalObject As New Journal(journalObjectHeader, journalObjectLineItems) 'Save it BRApi.Journals.Metadata.SaveJournalOrTemplateUsingIds(si, journalObject, False, True) ' Post the journal using ExecutePost BRApi.Journals.Process.ExecutePost(si, journalObjectHeader.UniqueID) brapi.ErrorLog.LogMessage(si, $"Journal '{journalObjectHeader.Name}' posted successfully.") Catch ex As Exception Throw ErrorHandler.LogWrite(si, New XFException(si, ex)) End Try End Sub16Views0likes0CommentsWorkspace Assembly - Call functions from Finance or Connector business rules
Hi Everyone, has anyone already tried to reference a Workspace Assembly business rule from a Finance or a Connector business rule? I have a business rule that is packaged to an Assembly in a Workspace: It has a set of public functions returning dictionaries and other variables. And I would like these functions being called from a Connector. I can successfully reference it from another Assembly workspace. But when I am using the same syntax in a connector, that is not working: I am assuming the referenced Business rule must be declared in the Properties, but I am not sure of the syntax. Or even sure this is accepted. Many thanks to anyone who can helps!Solved2.1KViews0likes11Comments