English (Español a continuación)
I.- @PRIOR
The @PRIOR function allows to select the data corresponding to a member of the outline that is located “x” positions to the right or to the left of the calculated member. It only works with zero-level members.
- Its structure consists of 3 parameters: @PRIOR (“Part A”, “Part B”, “Part C”)
Part A: determines the data (variable) to be selected.
- For example, Sales, Expenses, Income …
Part B: This parameter is optional; is a number «n» that determines the number of positions to move to the left (positive number) or right (negative number) from the calculated member.
- If not included, the defaults value is 1 (one movement to the left).
Let’s see an example: if the calculated memeber is “June”:

- If “n” = 2 this function selects “April”, while if “n” = -3 this function selects “September”.
Part C: This parameter is optional; sets the range through which the formule moves to locate the searched member. This series can be fixed in various ways:
C.1.- A list of simple or complex members.
- For example: («Madrid», «Barcelona», «Valencia», …)
C.2.- A function that determines a series of members.
- For example: @RELATIVE (“Markets”, 0)
C.3.- A range type function.
- For example: @XRANGE («2020» -> «January», «2021» -> «December»)
If not included Essbase moves through the zero-level members of the time dimension (January, February, March…).
Let’s see an example of this formula:
- “Sales 1” = @PRIOR (”Sales”, 2, @RELATIVE(“Months”, 0))
This function calculates the variable «Sales 1» which is equal to the variable «Sales», moving through the zero-level members of the dimension «Months», moving 2 positions to the left.

II.- @PRIORS
The @PRIORS function works exactly the same as the @PRIOR function with the difference that it includes one more parameter:
- @PRIOR («Part D», «Part A», «Part B», «Part C»)
That first parameter «Part D» determines the treatment given to the value 0 and the #missing. There are 4 options:
- SKIPNONE: treats 0 and #missing like the others values.
- SKIPMISSING: ignore #missing.
- SKIPZERO: ignore 0.
- SKIPBOTH: ignore both.
Let’s see some examples:
“Sales 1” = @PRIORS (SKIPNONE, ”Sales”, 2, @RELATIVE(“Months”, 0))

- In this example, the values 0 and #missing receive the same treatment as the rest of the values.
“Sales 1” = @PRIORS (SKIPZERO, ”Sales”, 2, @RELATIVE(“Months”, 0))

- In this example the value 0 is ignored so the “Sales 1” for the month of June equals the “Sales” for March.
“Sales 1” = @PRIORS (SKIPMISSING, ”Sales”, 2, @RELATIVE(“Months”, 0))

- In this example the #missing value is ignored so the “Sales 1” for the month of September equals the “Sales” for June.
“Sales 1” = @PRIORS (SKIPBOTH, ”Sales”, 2, @ RELATIVE (“Months”, 0))

- In this example the values 0 and #missing are ignored.
Any question, please send an email to: essbaseeasy@gmail.com
Español
I.- @PRIOR
La función @PRIOR permite seleccionar el dato correspondiente a un miembro del outline que se sitúa a “x” posiciones a la derecha o a la izquierda del miembro calculado. Únicamente funciona con miembros de nivel cero.
- Su estructura consta de 3 parámetros: @PRIOR(“Parte A”, “Parte B”, “Parte C”)
Parte A: determina el dato (variable) que va a seleccionar.
- Por ejemplo, Ventas, Gastos, Ingresos…
Parte B: Este parámetro es opcional; es un número “n” que determina el número de posiciones que hay que desplazarse hacia la izquierda (número positivo) o hacia la derecha (número negativo) desde el miembro calculado.
- Si no se establece Essbase toma por defecto el valor 1 (un movimiento hacia la izquierda).
Veamos un ejemplo: nos situamos en el miembro “junio”:

Si “n” = 2 esta función selecciona “Abril”, mientras que si “n” = -3 esta función selecciona “Septiembre”.
Parte C: Este parámetro es opcional; fija el rango por el que se va a mover la serie para localizar el miembro buscado. Esta serie se puede fijar de diversas maneras:
C.1.- Una lista de miembros simples o complejos.
- Por ejemplo: (“Madrid”,”Barcelona”,”Valencia”,…)
C.2.- Una función que determina una serie de miembros.
- Por ejemplo: @RELATIVE(“Mercados”,0)
C.3.- Una función de tipo rango.
- Por ejemplo: @XRANGE(“2020”->“Enero”,“2021”->“Diciembre”)
Si no se establece Essbase se mueve a través de los miembros de nivel cero de la dimensión tiempo (Enero, Febrero, Marzo…).
Veamos un ejemplo de esta fórmula:
- “Ventas 1” = @PRIOR(”Ventas”,2,@RELATIVE(“Meses”,0))
Esta función calcula la variable “Ventas 1” que es igual a la variable “Ventas”, moviéndose por los miembros de nivel cero de la dimensión “Meses”, desplazándose 2 posiciones hacia la izquierda.

II.- @PRIORS
La función @PRIORS funciona exactamente igual que la función @PRIOR con la diferencia de que incluye un parámetro más:
- @PRIOR(“Parte D”, “Parte A”, “Parte B”, “Parte C”)
Ese primer parámetro “Parte D” determina el tratamiento que le va a dar tanto a los 0 como a los #missing. Puede tomar 4 valores:
- SKIPNONE: trata a los 0 y a los #missing como a un valor más.
- SKIPMISSING: ignora los #missing.
- SKIPZERO: ignora los 0.
- SKIPBOTH: ignora ambos.
Veamos algunos ejemplos:
“Ventas 1” = @PRIORS(SKIPNONE,”Ventas”,2,@RELATIVE(“Meses”,0))

- En este ejemplo los valores 0 y #missing reciben el mismo tratamiento que el resto de valores.
“Ventas 1” = @PRIORS(SKIPZERO,”Ventas”,2,@RELATIVE(“Meses”,0))

- En este ejemplo el valor 0 es ignorado por lo que las “Ventas 1” del mes de Junio las iguala a las “Ventas” de Marzo.
“Ventas 1” = @PRIORS(SKIPMISSING,”Ventas”,2,@RELATIVE(“Meses”,0))

- En este ejemplo el valor #missing es ignorado por lo que las “Ventas 1” del mes de Septiembre las iguala a las “Ventas” de Junio.
“Ventas 1” = @PRIORS(SKIPBOTH,”Ventas”,2,@RELATIVE(“Meses”,0))

- En este ejemplo los valores 0 y #missing son ignorados.
Cualquier consulta envía, por favor, un correo a: essbaseeasy@gmail.com