Skip to main content

TRIM_LEADING

Removes all occurrences of the specified trim string from the beginning of the string.

See also:

Syntax

TRIM_LEADING(<string>, <trim_string>)

Examples

SELECT TRIM_LEADING('xxdatabend', 'xxx'), TRIM_LEADING('xxdatabend', 'xx'), TRIM_LEADING('xxdatabend', 'x');

┌────────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ trim_leading('xxdatabend', 'xxx') │ trim_leading('xxdatabend', 'xx') │ trim_leading('xxdatabend', 'x')
├───────────────────────────────────┼──────────────────────────────────┼─────────────────────────────────┤
│ xxdatabend │ 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