6 Working with database models and relations
This chapter covers
- Creating object types for database models
- Defining a global context shared among all resolvers
- Resolving fields from database models and transforming their names and values
- Resolving one-to-one and one-to-many relations
- Working with database views and join statements
Now that you’ve learned the core concepts of building a simple “static” schema and how to resolve its fields, it’s time to get real and learn how to resolve fields from databases. It’s time to implement the queries of the AZdev API. We’ll go through them one by one as we designed them in chapter 4 and learn the concepts we need as we use them.
Get GraphQL in Action now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.