pub fn pg_chr_decompose(payload: &str) -> StringExpand description
Postgres / Oracle CHR()-function decomposition — CHR(N) || CHR(N) || ...
per char of every single-quoted string literal.
Input 'admin' → output (CHR(97)||CHR(100)||CHR(109)||CHR(105)||CHR(110))
Differs from sql_char_decompose (which uses MySQL’s variadic
CHAR(N1,N2,...)) — Postgres / Oracle CHR() is unary, so codepoints
are concatenated via the SQL standard || pipe operator. The wrapping
parens preserve precedence inside larger expressions (WHERE u = ...).
Postgres-specific: codepoints up to U+10FFFF are valid; Oracle CHR(N)
treats N modulo NLS_CHARACTERSET size (often 256-modular for
WE8MSWIN1252). For ASCII payloads (the common case) both behave
identically.
Empty literal → (''). Unbalanced quote → passed through.