LOAD CSV functions

The functions described on this page are only useful when run on a query that uses LOAD CSV. In all other contexts they will always return null.

Functions:

linenumber()

linenumber() returns the line number that LOAD CSV is currently using.

Syntax: linenumber()

Returns:

An Integer.

Considerations:

null will be returned if this function is called without a LOAD CSV context.

If the CSV file contains headers, the headers will be linenumber 1 and the 1st row of data will have a linenumber of 2.

file()

file() returns the absolute path of the file that LOAD CSV is using.

Syntax: file()

Returns:

A String.

Considerations:

null will be returned if this function is called without a LOAD CSV context.