Formula Editor
The Formula Editor provides a visual interface for creating and maintaining formulas associated with members in a Casabase Cube dimension.
Because formulas in Casabase Cube are always associated with members, the Formula Editor is integrated directly into Edit Dimensions.
Select a member in the hierarchy to view, create, or modify the formula associated with that member.
Formula changes take effect when saved. A dimension rebuild is not required.
Opening the Formula Editor
Section titled “Opening the Formula Editor”To open the Formula Editor:
- Navigate to Edit Dimensions.
- Select the cube.
- Select the hierarchy containing the member.
- Select the member in the hierarchy tree.
- Locate the Formula Editor in the member editing pane.
The Formula Editor displays the formula information associated with the selected member.
If the member does not currently have a formula, you can enter a new native Casabase Cube formula and save it.
Source Formula and Cube Formula
Section titled “Source Formula and Cube Formula”For formulas originating from Oracle Essbase or Oracle Cloud EPM, the Formula Editor can display both the original source expression and the native Casabase Cube expression.
Source Formula
Section titled “Source Formula”Source Formula (Essbase/MDX - read-only) preserves the original formula imported from the source outline.
Conceptually:
Original Essbase Formula │ ▼ Source Formula (read-only)The Source Formula is retained for reference and comparison.
It is not the formula executed by the Casabase Cube query engine.
Cube Formula
Section titled “Cube Formula”The Cube Formula is the native Casabase Cube expression evaluated during query processing.
Conceptually:
Source Formula(Essbase/MDX) │ ▼Translation │ ▼Cube Formula(native Casabase Cube syntax) │ ▼Query-Time EvaluationFor formulas created directly in Casabase Cube, a Cube Formula can be authored without an imported Source Formula.
Editing the Cube Formula does not modify the read-only Source Formula.
See Formula Syntax for the native Casabase Cube formula language.
Creating a Formula
Section titled “Creating a Formula”To create a formula for a member:
- Navigate to Edit Dimensions.
- Select the cube and hierarchy.
- Select the member that should contain the formula.
- Enter the expression in the Formula Editor.
- Review the validation feedback.
- Click Save Cube Formula.
For example, a Gross Profit member could contain:
[ACCOUNT].[Revenue] - [ACCOUNT].[Cost of Sales]The formula becomes associated with the selected member and is evaluated dynamically when that member is queried.
Saving the formula does not require rebuilding the dimension.
Editing a Formula
Section titled “Editing a Formula”To modify an existing formula:
- Select the member in Edit Dimensions.
- Locate its existing Cube Formula.
- Modify the expression.
- Review the validation feedback.
- Click Save Cube Formula.
The updated formula becomes available to subsequent queries immediately after it is saved.
For migrated formulas, the original Source Formula remains unchanged.
Removing a Formula
Section titled “Removing a Formula”To remove a formula from a member:
- Select the member in Edit Dimensions.
- Clear the Cube Formula expression.
- Click Save Cube Formula.
The member remains in the hierarchy but no longer has a Cube Formula associated with it.
Removing a formula does not delete the member.
Member Picker
Section titled “Member Picker”The Member Picker helps build formulas without requiring member references to be typed manually.
Use it to browse members and insert qualified references such as:
[ACCOUNT].[Revenue]or:
[SCENARIO].[Actual]Inserted references can then be combined into larger expressions:
[ACCOUNT].[Revenue] - [ACCOUNT].[Cost of Sales]or cross-dimensional references:
[ACCOUNT].[Revenue]->[SCENARIO].[Actual]Using the Member Picker can help reduce errors caused by manually entering dimension or member names.
Formula Editing Tools
Section titled “Formula Editing Tools”The Formula Editor provides controls for common editing operations and formula constructs.
Available formula inserts can include constructs such as:
{ROW}NULLIFABSIIFCASEISLEAFISDESCISANCESTPARENTHASUDAISATTR
The editor also provides common editing controls such as:
- Undo
- Redo
- Format
These controls are editing conveniences. They insert or format syntax that is part of the native Casabase Cube formula language.
See:
Formula Validation
Section titled “Formula Validation”The Formula Editor provides validation feedback while a formula is being created or modified.
Treat formula validation primarily as a syntax and expression check. A formula can parse successfully and still contain a construct that the query engine refuses at runtime.
Validation can help identify conditions such as:
- Invalid formula syntax
- Unbalanced expression structures
- Invalid expression forms
- Potentially unsafe calculation patterns
For example, the editor may warn about division where the denominator is not protected against zero.
Instead of:
[ACCOUNT].[Gross Profit] / [ACCOUNT].[Revenue]use a protected denominator when appropriate:
[ACCOUNT].[Gross Profit]/NULLIF([ACCOUNT].[Revenue], 0)Validation is also available programmatically.
See Formula Validation for the complete validation workflow.
Solve Order
Section titled “Solve Order”The Formula Editor displays the Solve Order associated with the selected calculated member where that metadata is available.
Normal calculated-member dependencies are resolved automatically. For example, if Gross Margin % references Gross Profit, Casabase Cube resolves Gross Profit before evaluating the dependent formula.
Explicit solve order is primarily important when calculated members from different dimensions intersect in the same result cell.
For example:
ACCOUNT = Margin %SCENARIO = VarianceIf both members are calculated, their formulas can both affect the same intersection. The member with the higher solve-order value is applied later and therefore takes precedence.
Solve order is stored per member through the SOLVE_ORDER metadata supplied by the dimension definition.
See Solve Order & Dependencies before changing solve-order behavior.
Imported Essbase and Cloud EPM Formulas
Section titled “Imported Essbase and Cloud EPM Formulas”When an Oracle Essbase or Oracle Cloud EPM cube is migrated, formulas from the source outline can be translated into native Casabase Cube formulas.
The Formula Editor provides visibility into both forms:
| Formula | Purpose |
|---|---|
| Source Formula | Preserves the original imported Essbase/MDX expression for reference. |
| Cube Formula | Contains the native Casabase Cube expression used for query-time calculation. |
This makes it possible to compare the translated calculation with the original source logic while maintaining the executable Cube Formula independently.
The Source Formula remains read-only.
Formula Changes Do Not Require a Rebuild
Section titled “Formula Changes Do Not Require a Rebuild”Formula changes made through the Formula Editor do not require a dimension rebuild.
When you click Save Cube Formula, the updated expression becomes part of the member’s current cube configuration.
Subsequent queries that include the member can use the updated formula immediately.
This supports an iterative development workflow:
Select Member │ ▼Edit Formula │ ▼Validate │ ▼Save Cube Formula │ ▼Test in Query BuilderUse Query Builder to verify the calculated member against representative POVs after saving.
For detailed testing guidance, see Formula Validation and Best Practices.
Managing Formulas with SQL
Section titled “Managing Formulas with SQL”Formula management is also available programmatically through Casabase Cube stored procedures.
SET_FORMULA
Section titled “SET_FORMULA”SET_FORMULA can be used to assign or remove a formula associated with a member.
This can be useful for:
- Automated cube configuration
- Deployment processes
- Bulk administration
- Scripted formula changes
VALIDATE_FORMULA
Section titled “VALIDATE_FORMULA”VALIDATE_FORMULA provides a programmatic syntax check for workflows where formulas are maintained or checked outside the Formula Editor.
A successful validation does not guarantee that every construct can execute at query time. Always run a representative query after validation.
See Formula Validation for additional validation guidance.
Bulk Formula Loading
Section titled “Bulk Formula Loading”Formulas can also originate from the configured formula column in hierarchy source metadata.
This is useful when formula definitions are maintained as part of the dimension metadata rather than individually through the UI.
