Token Functions
The token functions in this section are used in the attribute expressions in the destination clause or as part of a condition in the WHERE
clause of a LOAD
statement.
Function | Output type | Description |
---|---|---|
|
Returns a string with the characters in the reverse order of the input string in_string. |
|
|
Returns a string which is the concatenation of all the input strings. |
|
|
Returns a version-4 UUID. |
|
gsql_split_by_space(in_string) |
|
Returns a modified version of in_string, in which each space character is replaced with ASCII 30 (decimal). |
|
Returns the substring beginning at beginIndex, having the given length. |
|
|
Returns the start index of the substring within the string. If it is not found, then return -1. |
|
|
Returns the length of the string. |
|
|
Returns the string resulting from replacing all matching substrings of oldToken with newToken in the original string. If a max count is provided, there can only be up to that many replacements. |
|
|
Returns the string resulting from replacing all substrings in the input string that match the given regex token with the substitute string. |
|
|
Returns true if the given string token matches the given regex token and false otherwise. |
|
|
Returns true if the in_string is either "t" or "true", with case-insensitive checking. Returns false otherwise. |
|
|
|
|
|
|
|
|
Converts a timestamp in canonical string format to Unix epoch time, which is the int number of seconds since Jan. 1, 1970. Refer to the timestamp input format note below. |
|
|
Returns the current time in Unix epoch seconds. By convention, the input parameter should be 0, but it is ignored. |
|
Splits a multi-value field into a set of records. Those records are first stored in a temporary table, and then the temporary table can be loaded into vertices and/or edges. |
||
Parses a JSON array of primitive values or JSON objects, as well as JSON objects in a column of a CSV file. |
||
Reads a compound token and splits it into a collection of elements, to form a set or list collection, or a map. |
||
|
Returns the input string in upper-case. |
|
|
Returns the input string in lower-case. |
|
|
Trims whitespace from the beginning and end of the input string. |
|
|
Trims white space from either the beginning or the end of the input string (Left or right). |
|
|
Returns 4-digit year from timestamp. |
|
|
Returns month (1-12) from timestamp. |
|
|
Returns day (1-31) from timestamp. |
|
|
Returns 4-digit year from Unix epoch time, which is the number of seconds since Jan. 1, 1970. |
|
|
Returns month (1-12) from Unix epoch time, which is the number of seconds since Jan. 1, 1970. |
|
|
Returns day (1-31) from Unix epoch time, which is the number of seconds since Jan. 1, 1970. |
|
|
Returns the ASCII (numeric) position of the first character in a string.
If the argument is an empty string, returns |
|
|
Converts an integer to a character according to its ASCII position.
If the input value |
|
|
Compares the Soundex codes of two strings and returns an integer from 0 to 4 indicating the similarity between the input strings' phonetic representation values. |
|
|
Returns the position of a string within a list of strings separated by commas. |
|
insert(str1, position[, number, str2)] |
|
Inserts a string within a string at the specified position and for a certain number of characters, and replaces a specified number of characters starting from the insertion position. |
|
Searches a string |
|
|
Extracts a number of characters from a string starting from position 0 and capturing left to right. |
|
|
Extracts a number of characters from a string starting from the last character and capturing right to left. |
|
|
Pads the left side of a string with another pad string. If the pad string pad_str is omitted, it will pad with white space. |
|
|
Pads the right side of a string (str) with another pad string. If the pad string (pad_str) is omitted, it will pad with white space. |
|
|
Returns a character string containing the Soundex code of str. |
|
|
Returns a string that contains the specified number of space characters. |
|
|
Replaces specified characters in a string with a different set of specified characters. |