Re: Problem in creating a table

From: Richard Huxton <dev(at)archonet(dot)com>
To: Wen Guangcheng <wen(at)microcourt(dot)co(dot)jp>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Problem in creating a table
Date: 2005-05-17 07:16:00
Message-ID: 42899A30.2080606@archonet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Wen Guangcheng wrote:
> Hi Gurus,
>
> When I try to create a table by a script I get a error as follows,
> #####################################################
> [postgres(at)demo pgsql]$ psql -d postgres -e -f /opt/rapisa/sql/TD_ACCESSCOUNT.sql
>
> CREATE TABLE TD_ACCESSCOUNT(
> AC_YEAR NUMBER(4,0) NOT NULL,
> AC_MONTH NUMBER(2,0) NOT NULL,
> AC_DAYS NUMBER(2,0) NOT NULL,
> OFFICE_ID VARCHAR2(7) NOT NULL,
^^^^^^^^
I don't think there is a varchar2.

> AC_COUNT NUMBER(6,0) DEFAULT 0,
> PRIMARY KEY("AC_YEAR","AC_MONTH","AC_DAYS","OFFICE_ID")

If you're going to quote names, ALWAYS quote them, otherwise let PG fold
them to lower-case.

--
Richard Huxton
Archonet Ltd

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Klint Gore 2005-05-17 07:17:00 Re: Problem in creating a table
Previous Message Wen Guangcheng 2005-05-17 06:47:55 Problem in creating a table