Lưu ý
Cần có ủy quyền mới truy nhập được vào trang này. Bạn có thể thử đăng nhập hoặc thay đổi thư mục.
Cần có ủy quyền mới truy nhập được vào trang này. Bạn có thể thử thay đổi thư mục.
Applies to:
Databricks SQL preview
Databricks Runtime 11.3 LTS and above
Returns the character length of string data or number of bytes of binary data. This function is a synonym for character_length function and char_length function.
Syntax
len(expr)
Arguments
expr: A STRING or BINARY expression.
Returns
An INTEGER.
The length of string data includes the trailing spaces. The length of binary data includes trailing binary zeros.
Examples
> SELECT len('Spark SQL ');
10
> SELECT len('床前明月光');
5