简体   繁体   English

PostgreSQL 命令中的列不存在错误

[英]Column doesnot exist error in PostgreSQL command

I have been trying to get the result of a PostgreSQL command.我一直在尝试获取 PostgreSQL 命令的结果。 I am getting the following error.我收到以下错误。 I want to get the video id, video name and the created date for that specific video.我想获取该特定视频的视频 ID、视频名称和创建日期。 在此处输入图像描述

I have all the required columns in the table as shown below:我在表中有所有必需的列,如下所示: 在此处输入图像描述

在此处输入图像描述

在此处输入图像描述

在此处输入图像描述

If you write "tablename.columnname" , that is not interpreted as table name and column name, but as a single identifier.如果您编写"tablename.columnname"则不会将其解释为表名和列名,而是作为单个标识符。 Based on the context in a join condition, PostgreSQL expects it to be a column name.根据连接条件中的上下文,PostgreSQL 期望它是一个列名。

If you use double quotes, you have to quote column and table separately: "tablename"."columnname"如果使用双引号,则必须分别引用列和表: "tablename"."columnname"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM