Loading

ES|QL TRIM function

Embedded
string

String expression. If null, the function returns null.

Removes leading and trailing whitespaces from a string.

string result
keyword keyword
text keyword
ROW message = "   some text  ",  color = " red "
| EVAL message = TRIM(message)
| EVAL color = TRIM(color)
		
message:s color:s
some text red