Skip to content
Advertisement

Tag: knex.js

knex postgres join as nested JSON

I’m using knex with postgresql db, I have a row in table A which has one-to-one relation to rows in table B and one-to-many relation to rows in table C. I wanna join a row from A with B and C and get a json like Where stuff like aCol means column from table A, bCol – column from table

Advertisement