Eric Grange wrote: > I am generating a json with json_object() function, and I would like to > omit the null or default fields from the output json
SELECT (SELECT json_group_object(key, value)
FROM json_each(json_object('field1', field1, 'field2', field2))
WHERE value IS NOT NULL)
FROM MyTable;
Regards,
Clemens
_______________________________________________
sqlite-users mailing list
[email protected]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users

