News for hackers. Stuff that matters.
Re:React, Relay and GraphQL: Under the Hood of the Times Web... by i_s on Saturday July 01, 2017 @04:18PM (#14678782)
> custom execution module to translate a graphql request to a single sql query

If I have a schema like this:

    users
      projects   (many per user)
      blog_posts (many per user)
What SQL do you generate to handle a request for everything in a single query?
Re:React, Relay and GraphQL: Under the Hood of the Times Web... by ruslan_talpa on Saturday July 01, 2017 @04:28PM (#14678824)
take a look at PostgREST https://github.com/begriffs/postgrest

simplified example query https://pastebin.com/7J2ZswRC

Re:React, Relay and GraphQL: Under the Hood of the Times Web... by i_s on Saturday July 01, 2017 @04:36PM (#14678867)
Ah, nice trick - thanks for the tip.