anchor.diff:  [[olap_functions]]
   = OLAP Functions
   
  -This section describes the syntax and semantics of the On Line
  -Analytical Process (OLAP) window functions. The OLAP window functions
  +On-line Analytical Process (OLAP) functions provide the capability to partition source data into groups of rows, order the rows in each group, compute aggregates within a window frame for a row. Typically, an OLAP function in SQL is expressed in two components <FUNCTION> and <OVER>: <FUNCTION> specifies the function and the arguments, and <OVER> specifies the partitioning, the ordering and the window frames. <OVER> is sometimes called the window. OLAP functions are used to perform analytic tasks against data sets stored in or computed from a set of tables, such as moving average and ranks.
  +
  +Trafodion also supports a set of sequence functions which are SQL extensions and have to be used together with a SEQUENCE BY clause. These sequence functions can be used to compute a running quantity of a column up to and include the current row as follows.
  +
  +* `RUNNINGAVG (column-expression)`: returns the average of non-null values. For more information, see <<runningavg_function,RUNNINGAVG Function>>.
  +* `RUNNINGCOUNT{(*) | (column-expression)}`: returns the number of rows up to and including the current row. For more information, see <<runningcount_function,RUNNINGCOUNT Function>>.
  +* `RUNNINGMAX(column-expression)`: returns the maximum of values of a column expression up to and including the current row. For more information, see <<runningmax_function,RUNNINGMAX Function>>.
  +* `RUNNINGMIN(column-expression)`: returns the minimum of values of a column expression up to and including the current row. For more information, see <<runningmin_function,RUNNINGMIN Function>>.
  +* `RUNNINGRANK(expression)`: Returns the rank of the given value of an intermediate result table ordered by a SEQUENCE BY clause in a SELECT statement. For more information, see <<runningrank_function,RUNNINGRANK Function>>.
  +* `RUNNINGSTDDEV(column-expression)`: returns the standard deviation of non-null values of a column expression up to and including the current row. For more information, see <<runningstddev_function,RUNNINGSTDDEV Function>>.
  +* `RUNNINGSUM(column-expression)`: returns the sum of non-null values of a column expression up to and including the current row. For more information, see <<runningsum_function,RUNNINGSUM Function>>.
  +* `RUNNINGVARIANCE(column-expression)`: returns the variance of non-null values of a column expression up to and including the current row. For more information, see <<runningvariance_function,RUNNINGVARIANCE Function>>.
  +
  +This section describes the syntax and semantics of the OLAP window functions. The OLAP window functions
   are ANSI compliant.
   
   [[considerations_for_window_functions]]
  
positive.code: ```
  
  <<<
  [[max_window_function]]
  === MAX Window Function
  
  MAX is a window function that returns the maximum value of all non null
  values of the given expression for the current window specified by the
  
negative.code: , VARIANCE (salary) OVER (PARTITION BY deptnum ORDER BY empnum ROWS UNBOUNDED PRECEDING)
  FROM persnl.employee;
  ```
  