postgresql - 在 Postgres 中左加入
问题描述
好的,这个 SQL 查询有什么问题:
select j.* from judge as j
left join user as u on j.user_id = u.id
where u.email="john@example.com";
ERROR: column "john@example.com" does not exist
解决方案
您在实际应该使用单引号的地方使用双引号。单引号表示值,而双引号表示列和表等。 您可以在此处找到有关差异的更多信息。
推荐阅读
- vba - 如何处理错误 1004 的许多不同类型的错误
- html - 无法在具有边框左上角半径和边框宽度的三角形对象中创建圆角左上角
- c++ - 将项目添加到队列时运行线程
- amazon-web-services - 如何使用 AWS 生成的密码在 AWS CLI 上正确创建 IAM 用户?
- bash - 使用 git bash 丢失文件
- kubernetes - kubectl config use-context 删除 eks 用户
- android - Direction Api 在 Android 谷歌地图中不起作用
- javascript - Mongo - 通过_id更新嵌套的对象数组
- raku - 如何基于逗号分割字符串,但不基于双引号中的逗号
- firebase - Firebase 仅部署功能流程