Skip to main content

Text

CONCAT

​​✔️ Safe to use in filter queries

Concatenates strings and returns the concatenated string.

Syntax

CONCAT(text1, text2, ...)

NameTypeDescription
text1mandatorytext1, text2,... are 1 to 100 text values which will be concatenated. Can be any expression that resolves to a string value.
text2mandatorytext1, text2,... are 1 to 100 text values which will be concatenated. Can be any expression that resolves to a string value.

ENDSWITH

​​✔️ Safe to use in filter queries

Checks whether a string ends with the characters of a specified string, returning true or false as appropriate.

Syntax

ENDSWITH(main_text, search_text)

NameTypeDescription
main_textmandatoryThe main string that will be searched. Can be any expression that resolves to a string value.
search_textmandatoryThe search string that will be checked whether it is at the end of the main string or not. Can be any expression that resolves to a string value.

HASHTAGS

​​❌ Cannot be used in filter queries

Extracts the hastags "#tag" in string and returns them in an array. Such as extracting hashtags from "Mentioning @altogic as #backend #platform" will return ["backend", "platform"]

Syntax

HASHTAGS(text)

NameTypeDescription
textmandatoryThe string to extract hashtags. The argument can be any valid expression that resolves to a string.

INCLUDES

​​✔️ Safe to use in filter queries

Checks whether the main string includes the characters of the search string, returning true or false as appropriate.

Syntax

INCLUDES(main_text, search_text, case_sensitive)

NameTypeDescription
main_textmandatoryThe main string that will be searched. Can be any expression that resolves to a string value.
search_textmandatoryThe search string that will be checked whether it is found within the main string or not. Can be any expression that resolves to a string value.
case_sensitiveoptionalSpecifies whether the search will be done case sensitive or insensitive (matches both upper and lower cases). Defaults to false (case insensitive) if unspecified.

INDEXOF

​​✔️ Safe to use in filter queries

Searches a string for an occurrence of a substring and returns the index (zero-based) of the first occurrence. If the substring is not found, returns -1.

Syntax

INDEXOF(main_text, substring, starting_index)

NameTypeDescription
main_textmandatoryThe main string that will be searched. Can be any expression that resolves to a string value.
substringmandatoryThe substring that will be checked whether it is found within the main string or not. Can be any expression that resolves to a string value.
starting_indexoptionalAn integer, or a number that can be represented as integers, that specifies the starting index position for the search. Can be any valid expression that resolves to a non-negative integer. If unspecified, the starting index position for the search is the beginning of the main text which is index 0

LEFT

​​✔️ Safe to use in filter queries

Returns the first count characters from the beginning of the main string as a new string.

Syntax

LEFT(text, count)

NameTypeDescription
textmandatoryThe string from which the substring will be extracted. Can be any valid expression as long as it resolves to a string.
countmandatoryCan be any valid expression as long as it resolves to a non-negative integer or number that can be represented as an integer.

​​❌ Cannot be used in filter queries

Extracts the links e.g., "http://www.example.com/info" in string and returns them in an array.

Syntax

LINKS(text)

NameTypeDescription
textmandatoryThe string to extract links. The argument can be any valid expression that resolves to a string.

LTRIM

​​✔️ Safe to use in filter queries

Removes whitespace characters (e.g., spaces) from the beginning of a string.

Syntax

LTRIM(text)

NameTypeDescription
textmandatoryThe string to trim. The argument can be any valid expression that resolves to a string.

MENTIONS

​​❌ Cannot be used in filter queries

Extracts the mentions "@username" in string and returns them in an array. Such as extracting mentions from "Mentioning @altogic and @backend" will return ["altogic", "backend"]

Syntax

MENTIONS(text)

NameTypeDescription
textmandatoryThe string to extract mentions. The argument can be any valid expression that resolves to a string.

REPLACE

​​❌ Cannot be used in filter queries

Returns a new string with some or all matches of search_text replaced by a replacement text.

Syntax‌‌

REPLACE(main_text, search_text, replace_text, case_sensitive)

NameTypeDescription
main_textmandatoryThe main string that will be replaced. Can be any expression that resolves to a string value.
search_textmandatoryThe search string that will be checked whether it is found within the main string or not. Can be any expression that resolves to a string value.
replace_textmandatoryThe replacement text that will be replaced for each search text match. Can be any expression that resolves to a string value.
case_sensitiveoptionalSpecifies whether the search will be done case sensitive or insensitive (matches both upper and lower cases). Defaults to false (case insensitive) if unspecified.

​​✔️ Safe to use in filter queries

Returns the last count characters from the end of the main string as a new string.

Syntax

RIGHT(text, count)

NameTypeDescription
textmandatoryThe string from which the substring will be extracted. Can be any valid expression as long as it resolves to a string.
countmandatoryCan be any valid expression as long as it resolves to a nonnegative integer or number that can be represented as an integer.

RTRIM

​​✔️ Safe to use in filter queries

Removes whitespace characters (e.g., spaces) from the end of a string.

Syntax

RTRIM(text)

NameTypeDescription
textmandatoryThe string to trim. The argument can be any valid expression that resolves to a string.

STARTSWITH

✔️Safe to use in filter queries

Checks whether a string starts with the characters of a specified string, returning true or false as appropriate.

Syntax

STARTSWITH(main_text, search_text)

NameTypeDescription
main_textmandatoryThe main string that will be searched. Can be any expression that resolves to a string value.
search_textmandatoryThe search string that will be checked whether it is at the beginning of the main string or not. Can be any expression that resolves to a string value.

STRCOMPARE

​​✔️ Safe to use in filter queries

Performs case-insensitive comparison of two strings. Returns 1 if first string is “greater than” the second string, 0 if the two strings are equal and -1 if the first string is “less than” the second string.

Syntax

STRCOMPARE(text1, text2)

NameTypeDescription
text1mandatoryCan be any expression that resolves to a string value.
text2mandatoryCan be any expression that resolves to a string value.

STRLEN

​​✔️ Safe to use in filter queries

Returns the number of characters in the specified string.

Syntax

STRLEN(text)

NameTypeDescription
textmandatoryThe string to get its character length. The argument can be any valid expression that resolves to a string.

SUBSTR

​​✔️ Safe to use in filter queries

Returns the substring of a string. The substring starts with the character at the specified index (zero-based) in the string for the number of characters (count) specified.

Syntax

SUBSTR(text, index, count)

NameTypeDescription
textmandatoryThe string from which the substring will be extracted. Can be any valid expression as long as it resolves to a string.
indexmandatoryIndicates the starting point of the substring. The index can be any valid expression as long as it resolves to a non-negative integer.
countmandatoryCan be any valid expression as long as it resolves to a non-negative integer.

TOLOWER

​​✔️ Safe to use in filter queries

Converts a string to lowercase and returns the resulting new string.

Syntax

TOLOWER(text)

NameTypeDescription
textmandatoryThe string to convert to lowercase. The argument can be any valid expression that resolves to a string.

TOUPPER

​​✔️ Safe to use in filter queries

Converts a string to uppercase and returns the resulting new string.

Syntax

TOUPPER(text)

NameTypeDescription
textmandatoryThe string to convert to uppercase. The argument can be any valid expression that resolves to a string.

TRIM

​​✔️ Safe to use in filter queries

Removes whitespace characters (e.g., spaces) from the beginning and end of a string.

Syntax

TRIM(text)

NameTypeDescription
textmandatoryThe string to trim. The argument can be any valid expression that resolves to a string.