Skip to main content

column_to_json

Function column_to_json 

Source
pub fn column_to_json(row: &Row, idx: usize, col_type: &Type) -> Value
Expand description

Convert a single Postgres column into a serde_json::Value, mapping common scalar types faithfully. Unknown types fall back to the column’s text representation. Used by both the SQL query endpoint (streaming rows to the CLI) and the WASM runtime’s host DB bridge.