Blog

Business rule and calc script errors in EPM Cloud: causes and fixes

A business rule fails at the worst possible moment: during a forecast cycle, with a planner waiting. This guide groups the errors that come up most often in EPM Cloud Planning (formerly PBCS) by what they look like, explains the usual cause, and gives the first thing to check. Messages are paraphrased where the exact wording varies between releases.

Start with the job console

Before changing anything, open the failed job in the Jobs console. The job details show the full error message, the rule's runtime prompt values and, for Groovy rules, anything the rule printed. Half of all "the rule is broken" reports turn out to be a rule run with the wrong prompt values.

1. Syntax errors when you validate or deploy

Calculation Manager reports these when you validate the rule, before it ever runs. Typical causes:

  • A missing semicolon after a statement, or an extra one after ENDFIX.
  • Unbalanced blocks: a FIX without ENDFIX, an IF without ENDIF, or parentheses that don't close.
  • An IF outside a member block. In a calc script, IF must sit inside a member block (or a member formula).
  • Unquoted member names that contain spaces, start with a number or match a function or command name.

Wrong, then right:

FIX(Forecast, Working)
  IF(@ISMBR(Jan))
    Revenue = Units * Price
  ENDIF
ENDFIX
FIX("Forecast", "Working")
  "Revenue" (
    IF (@ISMBR("Jan"))
      "Revenue" = "Units" * "Price";
    ENDIF
  )
ENDFIX

Quote every member name. It costs nothing and removes a whole class of errors.

2. Unknown or invalid members

The rule validated last month and fails today with a message that a member is unknown or invalid. Usual causes:

  • A member was renamed or deleted in a metadata change. Rules refer to members by name, not alias.
  • The member lives in another cube. A rule deployed to the reporting cube can't see input-cube-only members.
  • An alias was used instead of the member name, which works in forms but not in calc scripts.
  • A substitution variable is empty or points to a member that no longer exists, so &CurMonth expands to nothing.

Search the rule for the member named in the error, and check substitution variables before anything else after a month-end roll-forward.

3. Runtime prompt problems

A rule fails before calculating anything because a prompt is blank, is the wrong dimension, or is outside the members the prompt allows. Check the prompt's member limits and default values, and whether the form passes its POV members to the rule. A rule that expects a level 0 entity but receives a parent will often "work" and calculate far more than intended, so validate prompt values at the start of the rule (a Groovy rule can refuse with a clear message).

4. The rule runs, succeeds, and nothing changes

The most confusing case, because there is no error. Work through these in order:

  1. The blocks don't exist. A calc script only calculates existing blocks. Assigning a value inside a member block anchored on a sparse member, or inside an IF, won't create the block for a new entity or product. Create blocks first, for example with DATACOPY from a scenario that has data, or with a sparse assignment outside the IF. SET CREATENONMISSINGBLK ON also works but can be very slow; use it only on a tight FIX.
  2. The FIX excludes the data. A missing version, the wrong year substitution variable, or a member function that returns an empty set. SET EMPTYMEMBERSETS ON makes an empty member set stop the calculation instead of quietly calculating everything.
  3. The target member is dynamic calc. Values written to a dynamic calc member aren't stored.
  4. #MISSING arithmetic. In Essbase, #MISSING * 5 is #MISSING and #MISSING + 5 is 5. A rate that's missing in one period quietly produces missing results.
  5. The rule ran against a different cube from the one the form reads.

5. "Dynamic Calc processor cannot lock more than [n] ESM blocks"

This appears when a calculation touches many dynamic calc blocks at once, typically a calc script or formula that references dynamic upper-level members in a sparse dimension, or a member formula that drags in a large dynamic region. Fixes, from best to last resort:

  • FIX on level 0 members so the calculation doesn't need dynamic parents.
  • Reference stored members in formulas instead of dynamic totals where you can.
  • Split the calculation into smaller FIX blocks.
  • Only then consider changing the cache setting the message names, and talk to whoever owns the application before you do.

6. Slow rules and timeouts

A rule that took two minutes in testing and twenty in production usually has one of these:

  • FIX on dense members, or no FIX at all. Fix on sparse dimensions first; that's what limits the blocks touched.
  • Aggregating more than needed. AGG the sparse dimensions that changed, only for the slice that changed. In a hybrid cube, upper levels of dynamic sparse dimensions don't need aggregating at all.
  • Cross-dimensional references on the left side of an assignment, inside large loops.
  • Calculating in every period when the change only affects the open forecast months.
  • Pushing too much data to a reporting cube afterwards (see the Groovy cookbook for narrowing Smart Push).

Compare the job's duration before and after each change. Guessing at performance is how rules end up with every SET command anyone has ever heard of.

7. "Administrator has temporarily disabled user commands"

The application is open to administrators only. That happens during daily maintenance, during a database restructure or refresh, or when a service administrator put the application in administration mode for a change and didn't switch it back. Wait for the maintenance window to end, or ask the service administrator to set the application back to all users. If it happens at the same time every day, check when daily maintenance is scheduled.

8. Cube refresh fails with a network timeout

A refresh can fail with a message like "Network error: Timed out before receiving all data" (Essbase error 1042017), naming the cube. It usually means the refresh waited too long on a busy or locked cube: a long-running rule, a large data load or another refresh at the same time. Check the jobs console for what else was running, retry when it's quiet, and avoid scheduling refreshes on top of data loads. If it repeats with nothing else running, open a service request with Oracle Support and include the job details.

9. Groovy rule errors

Groovy rules fail in three ways:

  • Compilation errors at validation: a typo, a missing import or a method that doesn't exist. The message gives the line number.
  • Runtime exceptions: usually a null (a member that wasn't found) or an index outside a list. Add println around the failing line and read the job log.
  • Veto exceptions: these are intentional. The rule refused the save on purpose, and the message should say why.

A quick checklist

SymptomCheck first
Fails at validationSemicolons, ENDFIX/ENDIF, quoted member names
Unknown memberRecent metadata changes, substitution variables, alias vs. name
Runs, nothing changesBlock existence, the FIX scope, dynamic calc targets
Dynamic calc lock errorDynamic sparse parents in the calculation
SlowFIX on sparse dimensions, scope of AGG, Smart Push size
User commands disabledMaintenance window, administration mode
Refresh timeoutConcurrent jobs and data loads

Where EPM Agent fits

Many of these errors come from a rule drifting away from the decision it implements: a renamed member, a new entity, a changed driver. EPM Agent keeps the project's decisions as reviewed facts with their sources, and its build agents write rules as readable specifications from those decisions before compiling them. See how artifact builds work, or the companion reference on Essbase calc script functions.

See EPM Agent on a project like yours.

A fictive engagement end to end: a meeting, the knowledge it creates, and the artifacts built from it.