Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

关联表如何多条件联合查询 #836

Open
Kongdy opened this issue Nov 30, 2024 · 1 comment
Open

关联表如何多条件联合查询 #836

Kongdy opened this issue Nov 30, 2024 · 1 comment

Comments

@Kongdy
Copy link

Kongdy commented Nov 30, 2024

比如有两个表,User 和 UserInfo。
User 中有两个字段,isVip 和 userInfo, User 和 UserInfo 是一对一的关系。
UserInfo 中有年龄字段。

现在想查询 年龄大于 30,并且 isVip 是 true 的数据,返回所有 User,该如何操作呢

网上查了很多文章,提到使用 关联表.字段 的方式来判断,但是试了各种方式,都提示不识别 column

@Arsun
Copy link

Arsun commented Nov 30, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants