MaxL Language Definition


Syntax Notes
Numbers
Terminals
Privileges and Roles

Syntax Notes

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 BNF diagrams.

When issued via the MaxL Command 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 through Perl or API 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 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 any string that starts with an alphabetic character, or any quoted string. 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:

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 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.

The MaxL alphabet consists of the following elements:

Element Description
Special characters Valid special characters: .   ,   ;   :   %   $   "   '   SPACE   TAB   *   +   -   =   <   >   [   ]   {   }   (   )   ?   !   /   \   |   ~   `   #   &   @   ^  
Non-special characters Alphabetic characters and numbers.
Alphabetic characters Letters of the alphabet, and the underscore. [a-z, A-Z, _]
Numbers See Numbers

Numbers

Numbers in MaxL statements fit into one or more of the following categories.

POS-INT Zero or a positive integer. Decimals and scientific notation are permitted. Examples: 0, 1, 1000, 1.3e4
NEG-INT Zero or a negative integer. Decimals and scientific notation are permitted. Examples: 0, -1, -1000, -1.3e4
POS-REAL Zero or a positive real number. Decimals and scientific notation are permitted. Examples: 0.0, 1, 1000, 1000.4, 13.1e-4
NEG-REAL Zero or a negative real number. Decimals and scientific notation are permitted. Examples: 0.0, -1, -1000, -1000.4, -13.1e-4

Terminals

Terminal Expression Description
AREA-ALIAS name The location alias name of an area specification in the CREATE PARTITION statement.
APP-NAME name The name of the application. Limit 8 characters.

If the name contains special characters, it must be enclosed in single quotation marks.

Example: Sample
DBS-NAME name1.name2
  • name1 - The name of the application containing the database. Limit 8 characters.
  • name2 - The name of the database. Limit 8 characters.

The name of a database. Two tokens are required, to indicate application context.

If any part of the name contains special characters, it must be enclosed in single quotation marks.

Example: Sample.basic
CALC-NAME name1.name2.name3
  • name1 - Application name.
  • name2 - Database name.
  • name3 - Calc script name.

A stored calculation. Three tokens are required, to indicate application and database context.

If any part of the name contains special characters, it must be enclosed in single quotation marks.

Example: Sample.basic.'alloc.csc'

CALC-SPEC-STRING string An optional Hyperion Essbase calculator-syntax specification string. Must be enclosed in single quotation marks.

Example: '@COVARIANCE (expList1, expList2)'

Use CALC-SPEC-STRING only if the function or macro needs to be returned through the API that lists functions.
CALC-STRING string

A calculation string. The body of an anonymous (unstored) calculation, or the string used to specify the body of a stored calculation at create time.

Because calculations are terminated with a semicolon, and semicolons are special characters to MaxL, CALC-STRING should be enclosed in single quotation marks.

Example: CALC DIM(Year, Measures, Product);

COMMENT-STRING string A string of user-defined informational text. If the string contains special characters, it must be enclosed in single quotation marks.
Example: 'This is a comment.'
FILE-NAME string Short or full path name of a file. If the string contains special characters, it must be enclosed in single quotation marks.
Examples:
  • file01
  • 'D:\filename'
  • '/homes/fiona/scriptfile.msh'
FILTER-NAME name1.name2.name3
  • name1 - Application name.
  • name2 - Database name.
  • name3 - Filter name.

The name of a security filter. Three tokens are required, to indicate application and database context.

Example: Sample.basic.filt1
FUNC-NAME name1.name2 (application-level)
OR
name2 (system-level)
  • name1 - Application name.
  • name2 - Function name.

The name of a custom-defined Hyperion Essbase function. Using one token indicates a global function. For a local (application-level) function, use two tokens.

The name of a custom-defined function is a unique string that begins with a letter or a @, #, $, _ symbol. The name can include alphanumeric characters or the aforementioned symbols. It is recommended that you start a function name with @.

Any token of the name that contains special characters must be enclosed in single quotation marks.

Example:
  • Sample.'@COVARIANCE' (a local function)
  • '@COVARIANCE' (a global function)
GROUP-NAME name The name of a group.
Example: Sales
HOST-NAME name The name of a computer.
Example: Aspen
JAVACLASS.METHOD string The java class and the method representing the custom-defined function. Must be a fully qualified java method name and signature, enclosed in single quotation marks.
Example: 'com.hyperion.essbase.calculator.Statistics.covariance'
For Java code examples and MaxL registration scripts for custom-defined functions, see Custom-Defined Calculation Function Examples
LOCATION-ALIAS-NAME name1.name2.name3
  • name1 - Application name.
  • name2 - Database name.
  • name3 - Location alias name.

The name of a location alias referencing another database.
Example: Sample.Basic.EasternDB

MACRO-NAME name1.name2 (application-level)
OR
name2 (system-level)
  • name1 - Application name.
  • name2 - Macro name.

The name of a custom-defined Hyperion Essbase macro. Macro names are a shorthand way to refer to macro expansions.

The name of a macro is a unique string that begins with a letter or a @, #, $, _ symbol. The name can include alphanumeric characters or the aforementioned symbols. It is recommended that you start a macro name with @. Although macros must have unique names within a given application, a global macro and a local macro can share the same name. However, the local macro takes precedence.

To create or refer to a local (application-level) macro, use the double name (for example, Sample.'@JSUM').

Any part of the name that contains special characters must be enclosed in single quotation marks.

Examples:
  • Sample.'@COUNTRANGE' - Application-level (local) macro name without a signature, meaning that there are no restrictions on its arguments.
  • Sample.'@COUNTRANGE(Any)' - Same as Sample.'@COUNTRANGE'. Once registered for the application, @COUNTRANGE can take any arguments.
  • '@JCOUNTS' - System-level (global) macro name.
  • '@JCOUNTS(single,group)' - Same as '@JCOUNTS', but with a signature restricting its arguments.
For more information about macro signatures (input parameters), see Custom-Defined Macro Input Parameters
MACRO-EXPANSION string Extended definition of the macro, to be substituted in wherever the registered macro name is referenced in a calculation. If the string contains special characters, it must be enclosed in single quotation marks.
Example: '@COUNT(SKIPMISSING,@RANGE(@@S))'
For more information, see Custom-Defined Macros.
MEMBER-EXPRESSION string Outline member specification of members from one or more dimensions, member combinations separated by commas, or member sets defined with functions. Must be enclosed in single quotation marks.
Example: '@ANCESTORS(Qtr2)'.
MEMBER-NAME name The name of a database outline member.

If the name contains special characters, it must be enclosed in single quotation marks.

Examples:
  • Jan
  • 'New York'
NEW-ALIAS-NAME name The name of a new location alias you are creating from the current database to reference a remote database.
Example: EasternDB
PASSWORD string A user's password. If the string contains special characters, it must be enclosed in single quotation marks.
ROLE-NAME name The name of the security role. For more information, see Privileges and Roles.
Example: designer
SIZE-STRING number units
or
number
  • number - Any positive number. Decimals and scientific notation are permitted. Whitespace between number and units is optional.
  • units - One of the following: b, kb, mb, gb, tb (case-insensitive).
    If units are unspecified, bytes are assumed.
Examples:
51040b  51040 b  11MB  11000kb  12.34gb 1234e-2gb
USER-NAME name The name of the user. User names must start with a letter or a number. If the name contains special characters, it must be enclosed in single quotation marks.
VARIABLE-NAME name The name of the variable. If the name contains special characters, it must be enclosed in single quotation marks.
VOLUME-NAME name The name of the disk volume. On Windows, a drive letter. On UNIX, a path to the Essbase directory.

If the name contains special characters, it must be enclosed in single quotation marks.

Example: 'vol3/hyperion/essbase'.

Privileges and Roles

Essbase system privileges are indivisible database access types. In MaxL, privileges are grouped together to form permission-sets called roles. With the exception of create_user and create_application, privileges themselves are not grantable using MaxL; you typically grant roles, which are the equivalent of privilege levels. The scope of a role can be the system, the application, or the database.

While one privilege does not imply another, roles are hierarchical. The following table illustrates the Essbase system privileges that are contained in each MaxL system role.

MaxL System Role Essbase System Privileges
read write calculate design
database
create
database
start
application
design
application
create/drop
application
create/drop
user
no access . . . . . . . . .
read . . . . . . . .
write . . . . . . .
execute . . . . . .
designer (database) . . . . .
designer (application) . .
supervisor

System-Level System Privileges

The following privileges apply at the system level. These privileges are built-in; they do not apply to any specific application or database. They are not included in any role except for the role of supervisor.


create_application Ability to create and delete applications.
create_user Ability to create and delete users and groups.

System-Level System Roles

System-level system roles are applicable to the Hyperion Essbase system. The following roles have a system-wide scope:


no_access No access to the system.
supervisor Full access to the entire system, including other supervisors.

Application-Level System Roles

Application-level system roles are applicable to a Hyperion Essbase application. The following roles may have an application-wide scope:


no_access No access to the application or any databases within it.
designer Designer access to the application and any databases within it. Designer access means ability to create, delete, and modify databases within the application, in addition to having Read, Write, and Execute access for that application.

Database-Level System Roles

Database-level system roles are applicable to a Hyperion Essbase database. The following roles have a database-wide scope:


no_access No access to the database.
read Read-only access to the database. Read access means ability to view files, retrieve data values, and run report scripts.
write Write access to the database. Write access means ability to update data values, in addition to having Read access.
designer Designer access to the database. Designer access means ability to modify database outlines, in addition to having Read and Write access.

Filter Roles

The following subset of database-level system roles may be granted or revoked using filters.


no_access No access to the specified data object.
read Read-only access to the specified data object. Read access means ability to view files, retrieve data values, and run report scripts.
write Write access to the specified data object. Write access means ability to update data values, in addition to having Read access.

Copyright (c) 2000 Hyperion Solutions Corporation. All rights reserved.