Skip to main content

LTRIM

Introduced or updated: v1.2.694

Removes all occurrences of any character present in the specified trim string from the left side of the string.

See also:

Syntax

LTRIM(<string>, <trim_string>)

Examples

SELECT LTRIM('xxdatabend', 'xx'), LTRIM('xxdatabend', 'xy');

┌───────────────────────────────────────────────────────┐
│ ltrim('xxdatabend', 'xx') │ ltrim('xxdatabend', 'xy')
├───────────────────────────┼───────────────────────────┤
│ databend │ databend │
└───────────────────────────────────────────────────────┘
Try Databend Cloud for FREE

Multimodal, object-storage-native warehouse for BI, vectors, search, and geo.

Snowflake-compatible SQL with automatic scaling.

Sign up and get $200 in credits.

Try it today