我有以下表定义:
我正在尝试将一行插入如下所示的表格中:
我从手册中取出了这个命令,但它不起作用。我做错了什么?这是一件简单的事情,但我被难住了。这是我第一次使用postgres。
foo=# \d+ tag
Table "public.tag"
Column | Type | Modifiers | Storage | Stats target | Description
-------------+------------------------+--------------------------------------------------+----------+--------------+-------------
id | integer | not null default nextval('tag_id_seq'::regclass) | plain | |
name | character varying(255) | not null | extended | |
version | integer | not null | plain | |
description | character varying(255) | not null | extended | |
active | boolean | not null | plain | |
Indexes:
"tag_pkey" PRIMARY KEY, btree (id)
"unique_tag" UNIQUE CONSTRAINT, btree (name, version)
我正在尝试将一行插入如下所示的表格中:
foo=# insert into tag (name, version, description, active) values ("scala", 1, "programming language", true);
ERROR: column "scala" does not exist
LINE 1: ... tag (name, version, description, active) values ("scala", 1...
我从手册中取出了这个命令,但它不起作用。我做错了什么?这是一件简单的事情,但我被难住了。这是我第一次使用postgres。