Skip to main content
Version: v2.x

Databases

Introduction​

The Hasura GraphQL engine automatically generates your GraphQL schema and resolvers based on tables/views in your database . You don't need to write a GraphQL schema or resolvers. See How Hasura GraphQL engine works for more details.

The Hasura console gives you UI tools that speed up your data-modeling process, or working with your existing databases. The console also automatically generates migrations or metadata files that you can edit directly and check into your version control.

Supported databases​

Hasura GraphQL engine supports:

Tip

Although it is safe to use Hasura with a serverless database, caution must be maintained because some functionalities - such as subscriptions or event triggers - will force a serverless database to be always on.

Feature support​

The below matrices show the database wise support for the different GraphQL features under schema, queries, mutations and subscriptions.

Tip

Each ✅ below links directly to the feature within a particular type of database.

Schema​

PostgresCitusSQL ServerBigQueryCockroachDBCosmosDB
Table Relationships✅✅✅✅✅✅
Remote Relationships✅✅✅✅❌✅
Views✅✅✅✅✅✅
Custom Functions✅✅❌❌❌✅
Enums✅✅❌❌✅❌
Computed Fields✅❌❌✅❌❌
Data Validations✅✅✅✅✅✅
Relay Schema✅✅❌❌❌✅
Naming Conventions✅❌❌❌❌❌
Custom Fields✅✅✅✅✅✅

Queries​

PostgresCitusSQL ServerBigQueryCockroachDBCosmosDB
Simple✅✅✅✅✅✅
Nested Object✅✅✅✅✅✅
Aggregation✅✅✅✅✅✅
Filter / Search✅✅✅✅✅✅
Sort✅✅✅✅✅✅
Distinct✅✅✅✅❌✅
Paginate✅✅✅✅✅✅
Multiple Arguments✅✅✅✅✅✅
Multiple Queries✅✅✅✅✅✅
Variables / Aliases / Fragments✅✅✅✅✅✅

Mutations​

PostgresCitusSQL ServerBigQueryCockroachDBCosmosDB
Insert✅✅✅❌✅✅
Upsert✅✅✅❌✅✅
Update✅✅✅❌✅✅
Delete✅✅✅❌✅✅
Multiple per Request✅✅❌❌✅✅

Subscriptions​

PostgresCitusSQL ServerBigQueryCockroachDBCosmosDB
Value of Field✅✅✅❌✅✅
Updates to Rows✅✅❌❌✅✅
Value of Derived Field✅✅✅❌✅✅
Streaming Subscriptions✅✅❌❌✅✅

Event Triggers​

PostgresCitusSQL ServerBigQueryCockroachDBCosmosDB
INSERT✅❌✅❌❌❌
UPDATE✅❌✅❌❌❌
DELETE✅❌✅❌❌❌
MANUAL✅❌✅❌❌❌
Additional Resources

Get Started with Hasura today - Watch video guide.