↑↓ select ↵ open ⌫ change scope Open full search

PG.CENTER connects PostgreSQL documentation, reference, and ecosystem knowledge. Maintained by Pigsty.

Functions / String Functions And Operators

Removes the longest string containing only characters in characters (a space by default) from the start of string.

Reading PG 18current·documented in 27 of 27 versions, 7.1 to 20

Signatures & examples

ltrim ( string text [, characters text ] ) → text
Removes the longest string containing only characters in characters (a space by default) from the start of string.
ltrim('zzzytest', 'xyz') → test
ltrim ( bytes bytea, bytesremoved bytea ) → bytea
Removes the longest string containing only bytes appearing in bytesremoved from the start of bytes.
ltrim('\x1234567890'::bytea, '\x9012'::bytea) → \x34567890
Version history 5
  1. 13 → 14 changed
  2. 12 → 13 changed
  3. 7.4 → 8.0 changed
  4. 7.3 → 7.4 changed
  5. 7.2 → 7.3 changed

Definition snapshot: b7bd9cda · English manual source