vim: ft=help:tw=78:ts=8:norl:nolist:nonu:noml:

PG Table to JSON:
select row_to_json(t) from (select * from table) t #sql #postgres #json

JSON to SQL insert:
jq '.[] | "('\''\(.name)'\'',etc.)" #jq #json #sql

"x = NULL" occasionally works even though it's wildly wrong #sql
\d+ viewname shows you the SQL for creating a view on Postgres #sql #postgres
