English (Español a continuación)
There are several commands used to format the data.
- They are structure commands that are placed at the top of the Report Script (before entering the definition of Page / Columns / Rows).
1.- DECIMAL
This command is used to indicate the number of decimal places that the data of the indicated column(s) must show.
Its structure is:
- {DECIMAL Number | VARIABLE | ColumnX ColumnY…}
Number: indicates the number of decimal places; by default, it takes the value 0, with a maximum of 40 decimals.
VARIABLE: It is optional; allows to present the value in scientific notation format (E +00). It can be interesting to show the significant digits of the data when the width of the column is a restriction.
ColumnaX ColumnaY ColumnaZ…: It is optional and indicates with numbers the position of the columns to which you want to apply this format; these numbers are separated by space. If no column is specified, Essbase applies the number of decimal places to all data columns.
- The first column on the left of the Report Script is column 0, and as we move to the right the numbering increases.
For example: {DECIMAL 3 2 4}
- Applies 3 decimals to the data in the 2nd and 4th columns.
2.- MISSING TEXT
Replaces “#MISSING” values with alternative text.
Syntax:
- {MISSINGTEXT [Text]}
Text: is optional; is the text string to replace #MISSING values with; must be between “ “.
- If not specified, the #MISSING values are kept.
For example:
- {MISSINGTEXT “—“}
3.- ZERO TEXT
Replaces “0” values with alternative text.
Syntax:
- {ZEROTEXT [Text]}
Text: is optional; is the text string to replace zeros with; must be between “ “.
- If not specified, zero values are kept.
For example:
- {ZEROTEXT “NULL”}
4.- AFTER / BEFORE
These two commands are used to insert a character (for example: %, $…) next to the data:
- {AFTER} inserts it after the data.
- {BEFORE} inserts it before the data.
The syntax of both commands is similar:
- {AFTER “Character” “List of columns”}
- {BEFORE «Character» «List of Columns»}
Character: must be enclosed in quotes and must only occupy one position (if a longer string is included, Essbase only includes the first character).
- In both commands, if no character is defined («» is specified), the input of the character that had been defined in a previous command is deleted from that moment on.
Column list: is optional; refers to the numbers of the data columns to which this character is going to be included (these numbers must be separated by spaces).
- The first column from the left is column 0, and as we move to the right it increases.
- If column list is not included Essbase adds this character to all data columns.
If the data is #MISSING (or the value with which it has been replaced), this character is not added.
5.- BRACKET
This command allows negative numbers to be presented in parentheses instead of with the «-» sign.
- It is the default option, so you only have to use it to remove the effect of the {SUPBRACKET} command if it has been used before.
Syntax:
- {BRACKETS}
The {SUPBRACKET} command removes the default display of negative numbers in parentheses to display them with the «-» sign.
6.- COMMAS
This command displays thousands signs with “commas”.
- For example: 2336363 is displayed as 2,336,363
Syntax:
- {COMMAS}
To remove thousands signs, use the {SUPCOMMAS} or {SUPALL} commands.
With these two commands:
- The number 3,412,566.23 is presented as 3412566.23
By default, numbers are displayed with thousands signs.
7.- EUROPEAN
Syntax:
- {EUROPEAN}
By default Essbase presents the numbers in the Report Script with the American notation:
- The thousands separator with a comma.
- The decimal separator with a point.
For example:
- 1,345,665.23
With this command the following are displayed:
- The thousands separator with a dot.
- The decimal separator with a comma.
For example:
- 1,345,665.23
The effect of the previous command is canceled with the command {SUPEUROPEAN}.
8.- SCALE
This command allows you to multiply all the data in a column by a given number.
Syntax:
- {SCALE “Factor” “List of columns”}
Factor: is the number by which the data in the column(s) will be multiplied.
- For example: 1.5
Column list: is optional; selects all the data columns to which this factor is going to be applied.
- The first column on the left of the Report Script is column 0, and as we move to the right the numbering increases.
- If this command is not mentioned, it will be applied to all data columns.
Example:
- {SCALE 0.9 4 5}
This command multiplies the data in columns 4th and 5th by 0.9.
Español
Existen diversos comandos que sirven para dar formato a los datos.
- Son comandos de estructura que se sitúan en la parte superior del Report Script (antes de entrar en la definición de Página / Columnas / Filas).
1.- DECIMAL
Este comando se utiliza para indicar el número de decimales que deben mostrar los datos de la(s) columna(s) que se le indique(n).
Su estructura es:
- {DECIMAL Número | VARIABLE | ColumnaX ColumnaY…}
Número: indica el número de decimales; por defecto toma el valor 0, siendo el máximo 40 decimales.
VARIABLE: Es opcional; permite presentar el valor en formato de notación científica (E +00). Puede resultar interesante para mostrar los dígitos significativos de los datos cuando la anchura de la columna supone una restricción.
ColumnaX ColumnaY ColumnaZ…: Es opcional e indica con números la posición de las columnas a las que se quiere aplicar este formato; estos números van separados por espacio. Si no se indica ninguna columna Essbase aplica el número de decimales a todas las columnas de datos.
- La primera columna de la izquierda del Report Script es la columna 0, y a medida que nos desplazamos hacia la derecha va aumentando la numeración.
Por ejemplo: {DECIMAL 3 2 4}
- Aplica 3 decimales a los datos de las columnas 2º y 4ª.
2.- MISSINGTEXT
Sustituye los valores “#MISSING” por un texto alternativo.
Sintaxis:
- {MISSINGTEXT [Texto]}
Texto: es opcional; es la cadena de texto por la que se sustituyen los valores #MISSING; debe ir entre “ “.
- Si no se especifica se mantienen los valores #MISSING.
Por ejemplo:
- {MISSINGTEXT “—“}
3.- ZEROTEXT
Sustituye los valores “0” por un texto alternativo.
Sintaxis:
- {ZEROTEXT [Texto]}
Texto: es opcional; es la cadena de texto por la que se sustituyen los ceros; debe ir entre “ “.
- Si no se especifica se mantienen los valores ceros.
Por ejemplo:
- {ZEROTEXT “NULL”}
4.- AFTER / BEFORE
Estos dos comandos se utilizan para insertar un carácter (por ejemplo: %, $…) junto a los datos:
- {AFTER} lo introduce detrás del dato.
- {BEFORE} lo introduce delante del dato.
La sintaxis de ambos comandos es similar:
- {AFTER “Carácter” “Lista de columnas”}
- {BEFORE “Carácter” “Lista de columnas”}
Carácter: debe ir entre comillas y tan sólo debe ocupar una posición (si se incluye una cadena más larga Essbase tan sólo incluye el primer carácter).
- En ambos comandos, si no se define ningún carácter (se especifica “”) se eliminan a partir de ese momento en adelante la introducción del carácter que se había definido en un comando anterior.
Lista de columnas: es opcional; hace referencia a los números de las columnas de datos a los que se les va a incluir este carácter (estos números han de ir separados por espacios).
- La primera columna de la izquierda es la columna 0, y a medida que nos desplazamos hacia la derecha va aumentando.
- Si no se incluye lista de columna Essbase añade este carácter a todas las columnas de datos.
Si el dato es #MISSING (o el valor por el que se ha reemplazado) no se le añade este carácter.
5.- BRACKET
Este comando permite presentar los números negativos entre paréntesis en lugar de con el signo “-“.
- Es la opción por defecto, por lo que sólo hay que utilizarlo para eliminar el efecto del comando {SUPBRACKET} si se ha utilizado anteriormente.
Sintaxis:
- {BRACKET}
El comando {SUPBRACKET} elimina la presentación por defecto de los números negativos entre paréntesis para presentarlos con el signo “-“.
6.- COMMAS
Este comando muestra los signos de miles con “comas”.
- Por ejemplo: 2336363 se muestra como 2,336,363
Sintaxis:
- {COMMAS}
Para eliminar los signos de miles se utilizan los comandos {SUPCOMMAS} o {SUPALL}.
Con estos dos comandos:
- El número 3,412,566.23 se presenta como 3412566.23
Por defecto los números se muestran con signos de miles.
7.- EUROPEAN
Sintaxis:
- {EUROPEAN}
Por defecto Essbase presenta los números en el Report Script con la notación americana:
- El separador de miles con coma.
- El separador de decimales con punto.
Por ejemplo:
- 1,345,665.23
Con este comando se muestran:
- El separador de miles con punto.
- El separador de decimales con coma.
Por ejemplo:
- 1.345.665,23
El efecto del comando anterior se anula con el comando {SUPEUROPEAN}.
8.- SCALE
Este comando permite multiplicar todos los datos de una columna por un número determinado.
Sintaxis:
- {SCALE “Factor” “Lista de columnas”}
Factor: es el número por el que se van a multiplicar los datos de la(s) columna(s).
- Por ejemplo: 1.5
Lista de columnas: es opcional; recoge todas las columnas de datos a las que se les va a aplicar este factor.
- La primera columna de la izquierda del Report Script es la columna 0, y a medida que nos desplazamos hacia la derecha va aumentando la numeración.
- Si no se menciona este comando se aplicará a todas las columnas de datos.
Ejemplo:
- {SCALE 0.9 4 5}
Este comando multiplica por 0,9 los datos de las columnas 4ª y 5ª.