Skip to content

calc/fix-trailing-comma

Starts at Error. It reads Calc Script files in Rules, Templates, and Scripts, and needs nothing but the file you have open.

It looks at the member list of every FIX(, FIXPARALLEL(, and EXCLUDE( for a comma just before the closing bracket. It finds the comma even when the list runs over several lines, or a comment sits between the comma and the bracket.

  • Commas and brackets inside a quoted member name, such as "T(FIN)", don’t confuse it.
  • An empty last argument inside a function in the list is left alone. Some functions, such as @CURRMBRRANGE, let you skip optional arguments that way.

Oracle rejects the script at Deploy with a general error that names no line and no character. Nothing in that error points at the comma, so finding it means checking the member list by hand. Catching it as you type saves the trip.

FIX("Budget", "Working", "FY26", )
"Net Income" = "Revenue" - "Total Expenses";
ENDFIX

The comma is underlined, and the message reads:

Trailing comma inside `FIX( … )` — Calc Manager rejects it with a generic error. Remove the comma before `)`.

The message names the keyword that opened the list, so on a parallel block it reads FIXPARALLEL( … ), and on an exclusion EXCLUDE( … ).

Corrected:

FIX("Budget", "Working", "FY26")
"Net Income" = "Revenue" - "Total Expenses";
ENDFIX

Click the underlined comma and press Ctrl+. (Cmd+. on a Mac), then choose Remove trailing comma. It deletes that one comma and nothing else.

Change its level (Error, Warning, Info) or turn it off in the Lint Rules panel, or excuse one file with a Lint Exception.

There is rarely a good reason to do either. Oracle rejects every script this Lint Rule reports.