Sign up for Hasura Newsletter
Loading...

创建关系

既然已创建外键约束,Hasura 控制台会自动建议基于该约束的关系。

转到todos表下的Relationships选项卡,应该就会看到如下建议的关系:

待办事项关系页面

在建议的对象关系中单击Add

将关系名称输入为user(已预填写),然后单击Save

用户对象关系

现在已在待办事项和用户表之间建立了关系。

Did you find this page helpful?
Start with GraphQL on Hasura for Free
  • ArrowBuild apps and APIs 10x faster
  • ArrowBuilt-in authorization and caching
  • Arrow8x more performant than hand-rolled APIs
Promo
footer illustration
Brand logo
© 2024 Hasura Inc. All rights reserved
Github
Titter
Discord
Facebook
Instagram
Youtube
Linkedin