Function jsonb_object_field_str

Source
pub fn jsonb_object_field_str(
    v: JsonbRef<'_>,
    p: &str,
    writer: &mut impl Write,
) -> Option<()>
Expand description

Extracts JSON object field with the given key, as text.

jsonb ->> text → text

§Examples

query T
select '{"a":1,"b":2}'::jsonb ->> 'b';
----
2

query T
select '{"a":1,"b":null}'::jsonb ->> 'b';
----
NULL