Re: What's wrong with this SQL?

Поиск
Список
Период
Сортировка
От Dann Corbit
Тема Re: What's wrong with this SQL?
Дата
Msg-id D425483C2C5C9F49B5B7A41F8944154757D8F0@postal.corporate.connx.com
обсуждение исходный текст
Ответ на What's wrong with this SQL?  ("Adam" <adam@spatialsystems.org>)
Список pgsql-general
If you count over 39 characters, you will see the parser is barking at
this:

"user_ID" SERIAL(12)
                ^

See:
http://www.postgresql.org/docs/8.1/static/datatype.html#DATATYPE-SERIAL

to find out why your definition is confusing Mr. SQL-parser.

> -----Original Message-----
> From: pgsql-general-owner@postgresql.org [mailto:pgsql-general-
> owner@postgresql.org] On Behalf Of Adam
> Sent: Tuesday, May 09, 2006 9:06 PM
> To: pgsql-general@postgresql.org
> Subject: [GENERAL] What's wrong with this SQL?
>
> I'm trying to create a table and I'm getting this error:
>
>       SQL error:
>
>
> ERROR:  syntax error at or near "(" at character 39
>       In statement:
>       CREATE TABLE "users" ("user_ID" SERIAL(12), "first_name"
character
> varying(40) NOT NULL, "last_name" character varying(40) NOT NULL,
> "password"
> character varying(16) NOT NULL, "email" character varying(100) NOT
NULL,
> "privilege" integer(2) NOT NULL, PRIMARY KEY ("user_ID"))
>
>
>
>       What's wrong with this SQL?
>
>
>
> ---------------------------(end of
broadcast)---------------------------
> TIP 6: explain analyze is your friend

В списке pgsql-general по дате отправления:

Предыдущее
От: "Adam"
Дата:
Сообщение: What's wrong with this SQL?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: What's wrong with this SQL?