Determine row number. More...
#include "sqlstat.h"
Go to the source code of this file.
Classes | |
struct | rownumber_storage |
Storage for rownumber function. More... | |
Functions | |
my_bool | rownumber_init (UDF_INIT *initid, UDF_ARGS *args, char *message) |
Called before first usage of function. More... | |
long long | rownumber (UDF_INIT *initid, UDF_ARGS *args, char *is_null, char *error) |
Retrieve row number. More... | |
void | rownumber_deinit (UDF_INIT *initid) |
Called after last access to function. More... | |
Determine row number.
CREATE FUNCTION rownumber RETURNS INTEGER SONAME 'libsqlstat.so';
SELECT rownumber() FROM mytab;
DROP FUNCTION rownumber;
Definition in file rownumber.c.
double rownumber | ( | UDF_INIT * | initid, |
UDF_ARGS * | args, | ||
char * | is_null, | ||
char * | error | ||
) |
Retrieve row number.
initid | function description |
args | argument values |
is_null | result is NULL |
error | error message |
Definition at line 84 of file rownumber.c.
rownumber_deinit | ( | UDF_INIT * | initid | ) |
Called after last access to function.
Deallocate memory for counter.
initid |
Definition at line 104 of file rownumber.c.
my_bool rownumber_init | ( | UDF_INIT * | initid, |
UDF_ARGS * | args, | ||
char * | message | ||
) |
Called before first usage of function.
Checksparameters.
Indicate type of return value.
initid | function description |
args | parameters |
message | error message |
Definition at line 51 of file rownumber.c.