Thread: ...

...

From
"minfrin@sharp.fm"
Date:
If PostgreSQL failed to compile on your computer or you found a bug that
is likely to be specific to one platform then please fill out this form
and e-mail it to pgsql-ports@postgresql.org.

To report any other bug, fill out the form below and e-mail it to
pgsql-bugs@postgresql.org.

If you not only found the problem but solved it and generated a patch
then e-mail it to pgsql-patches@postgresql.org instead.  Please use the
command "diff -c" to generate the patch.

You may also enter a bug report at http://www.postgresql.org/ instead of
e-mail-ing this form.

============================================================================
                        POSTGRESQL BUG REPORT TEMPLATE
============================================================================


Your name        :    Graham Leggett
Your email address    :    minfrin@sharp.fm


System Configuration
---------------------
  Architecture (example: Intel Pentium)      : PPC G3

  Operating System (example: Linux 2.0.26 ELF)     : Linux 2.4.18pre1

  PostgreSQL version (example: PostgreSQL-7.1.3): PostgreSQL-7.1.3

  Compiler used (example:  gcc 2.95.2)        :


Please enter a FULL description of your problem:
------------------------------------------------

COPY complains that a relation does not exist, just after that table
is created.



Please describe a way to repeat the problem.   Please try to provide a
concise reproducible example, if at all possible:
----------------------------------------------------------------------

If the following file contents are issued to psql:

CREATE SEQUENCE "ContainerDetail_sequence" start 27 increment 1 maxvalue 2147483647
minvalue 1  cache 1 ;

CREATE TABLE ContainerDetail (
    RecordID int DEFAULT nextval('ContainerDetail_sequence') NOT NULL,
    PackList varchar (35)  NOT NULL ,
    ExternalDim varchar (35)  NULL ,
    InternalDim varchar (35)  NULL ,
    ExternalVol decimal(18, 4) NULL ,
    InternalVol decimal(18, 4) NULL
)
;

COPY "ContainerDetail" FROM '/tmp/ContainerDetail' USING DELIMITERS ',';

The above bombs out like so:

CREATE
CREATE
ERROR:  Relation 'ContainerDetail' does not exist

(Unless I am doing something really stupid) the error is saying that a table
does not exist when it does.

The same problem exists if the data is imported from stdin.



If you know how this problem might be fixed, list the solution below:
---------------------------------------------------------------------