Skip to main content

json_object_expr

Function json_object_expr 

Source
fn json_object_expr(columns: &[String]) -> Expr
Expand description

Builds a JSONB object with one entry per column: key = the column name, value = the column rendered as a string, NULL coalesced to "" so one NULL column does not null the entry (descriptive columns are nullable). Keys come out sorted — JSONB objects are key-ordered regardless of input order.