多维表格
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

3.4 KiB

title description tags keywords
String functions This article explains various string functions that can be used in formula fields. [Fields Field types Formula] [Fields Field types Formula Create formula field String functions]

String functions

Name Syntax Sample Output
CONCAT CONCAT(str1, [str2,...]) CONCAT({field1}, ' ', {field2}) Concatenated string of input parameters
LEFT LEFT(str1, n) LEFT({field}, 3) n characters from the beginning of input parameter
LEN LEN(str) LEN({field}) Input parameter character length
LOWER LOWER(str) LOWER({field}) Lower case converted string of input parameter
MID MID(str, position, [count]) MID({field}, 3, 2) Alias for SUBSTR
REPEAT REPEAT(str, count) REPEAT({field}, 2) Specified copies of the input parameter string concatenated together
REPLACE REPLACE(str, srchStr, rplcStr) REPLACE({field}, 'int', 'num') String, after replacing all occurrences of srchStr with rplcStr
RIGHT RIGHT(str, n) RIGHT({field}, 3) n characters from the end of input parameter
SEARCH SEARCH(str, srchStr) SEARCH({field}, 'str') Index of srchStr specified if found, 0 otherwise
SUBSTR SUBTR(str, position, [count]) SUBSTR({field}, 3, 2) Substring of length 'count' of input string, from the postition specified
TRIM TRIM(str) TRIM({field}) Remove trailing and leading whitespaces from input parameter
UPPER UPPER(str) UPPER({field}) Upper case converted string of input parameter
URL URL(str) URL({field}) Convert to a hyperlink if it is a valid URL
REGEX_MATCH REGEX_MATCH(str, pattern) REGEX_MATCH({field}, 'a.*') Returns 1 if the input text matches a regular expression or 0 if it does not
REGEX_EXTRACT REGEX_EXTRACT(str, pattern) REGEX_MATCH({field}, 'a.*') Returns the first match of a regular expression in a string
REGEX_REPLACE REGEX_REPLACE(str, pattern, replacer) REGEX_MATCH({field}, 'a.*', '---') Replaces all matches of a regular expression in a string with a replacement string