graphene-sqlalchemy icon indicating copy to clipboard operation
graphene-sqlalchemy copied to clipboard

Added an `Aggregation` section to the `tips` documentation page.

Open somada141 opened this issue 6 years ago • 4 comments

Added an Aggregation section to tips.rst to show how to retrieve the session out of info and perform an aggregation query wrapping the results in a custom type and exposing it to the schema.

somada141 avatar Oct 03 '18 03:10 somada141

Coverage Status

Coverage remained the same at 91.854% when pulling 28ae4ff0bbb901b1624ed45a5195762e131d16f1 on somada141:feature/doc-tips-aggregation into 33d5b746719a4a0fb19d00337b1ed87fe40802a9 on graphql-python:master.

coveralls avatar Oct 03 '18 03:10 coveralls

Coverage Status

Coverage remained the same at 91.854% when pulling 28ae4ff0bbb901b1624ed45a5195762e131d16f1 on somada141:feature/doc-tips-aggregation into 33d5b746719a4a0fb19d00337b1ed87fe40802a9 on graphql-python:master.

coveralls avatar Oct 03 '18 03:10 coveralls

Coverage Status

Coverage remained the same at 91.854% when pulling 28ae4ff0bbb901b1624ed45a5195762e131d16f1 on somada141:feature/doc-tips-aggregation into 33d5b746719a4a0fb19d00337b1ed87fe40802a9 on graphql-python:master.

coveralls avatar Oct 03 '18 03:10 coveralls

@somada141 Nice example, but is it really related to graphene ?

The "tips" is "how to retrieve easily the sqlalchemy session from graphene context", but all the "what you can do with the query" is more sqlalchemy stuff than graphene stuff, no ? So maybe most of the code you wrote should go as example in the appropriated directory instead of in the tips ?

(we can merge that this way and create a fully functional aggragation example later)

Nabellaleen avatar Mar 18 '19 10:03 Nabellaleen