alloc / tusken

100% type-safe query builder compatible with any Postgres client 🐘 Generated table/function types, tree-shakable, implicit type casts, and more
Other
223 stars 3 forks source link

Add helper for converting json array into a set #2

Closed aleclarson closed 2 years ago

aleclarson commented 2 years ago

Whose SQL would be similar to:

FROM json_to_recordset(yourJsonValue -> 'rows') AS rows(columns JSON),
     json_to_record(columns) AS cols(
       "Nombre" TEXT,
       "rutaEsquema" TEXT,
       "TipoDeComponente" TEXT,
       "detalleDelComponente" TEXT)
aleclarson commented 2 years ago

Duplicate of #6