MaxL Syntax Notes

MaxL syntax is comprised of statements, tokens, keywords, terminals names, strings, numbers, and delimiters.

The following syntax scheme applies to the creation of MaxL statements.

A MaxL statement corresponds to a sentence telling Essbase what to do with users and database objects. In this documentation, the grammar of MaxL statements is illustrated using railroad diagrams.

When issued via the MaxL Shell (essmsh), statements must be terminated by semicolons. Semicolons are used only to tell the shell when to terminate the statement; semicolons are not part of the MaxL language itself. Therefore, when issuing MaxL statements programmatically external programs, do not terminate with a semicolon.

A token is a delimited sequence of characters recognized by MaxL as a single readable unit. Tokens may be singleton names, keywords, strings, or numbers. Names can have one, two, or three tokens, delimited by periods. The space delimiting tokens can be any white space: spaces, tabs, new lines, or blank lines.

A keyword is a sequence of alphabetic characters that is part of the MaxL grammar. Each keyword is recognized as one token. To be recognized as keywords, keywords cannot be enclosed in quotation marks. However, if you wish to use MaxL keywords outside of the grammar as terminals (for example, as database names or passwords), they must be enclosed in single or double quotation marks.

A terminal is something referenced in the grammar for which you provide the correct name or definition. Terminals can be names, numbers, or strings. Examples: user-name, filter-name, size-string.

A name is a string which can be quoted or unquoted. Unquoted names must begin with an alphabetic character. Quoted names can consist of any sequence of characters. Names in MaxL are used to uniquely identify databases and database objects, such as users, applications, or filters.

Names in MaxL may be one of three types:

  • singletons, which are names with one token (example: Sample). Use a singleton name for objects that have a system-wide context: for example, applications.

  • doubles, which are names with two tokens. A double is two names connected by a period (example: Sample.basic). Use doubles to name objects with application-wide contexts, such as databases.

  • triples, which are names with three tokens. A triple is three names connected by two periods (example: Sample.Basic.Calcname). Use triples to name objects having database-wide contexts, such as filters.

A string is unquoted or quoted. An unquoted string can be any sequence of non-special characters. A quoted string can be any sequence of characters (special, alphabetic, or numeric) in the MaxL Alphabet, enclosed in single or double quotation marks.

A number is one kind of token which may be passed to Essbase by MaxL. To have meaning, the number must be in the correct format for the Essbase value it represents. In the MaxL grammar documentation, labels for numbers indicate whether the allowed number is positive, negative, an integer, or a real. See Numbers in MaxL Syntax.

The MaxL alphabet consists of the following elements:

Table 3-20 MaxL Alphabet Elements

Element Description
Special characters Valid special characters: . , ; : % $ " ' SPACE TAB * + - = < > [ ] { } ( ) ? ! / \ | ~ ` # & @ ^

When using special characters in MaxL terminals, note the quoting rules (see Quoting and Special Characters Rules for MaxL Language).

Non-special characters Alphabetic characters and numbers.
Alphabetic characters Letters of the alphabet, and the underscore. [a-z, A-Z, _]
Numbers See Numbers in MaxL Syntax