Re: CREATE SEQUENCE

Lists: pgsql-general
From: Grant <emailgrant123b(at)yahoo(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: CREATE SEQUENCE
Date: 2004-08-03 04:30:52
Message-ID: 20040803043052.44846.qmail@web53201.mail.yahoo.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

I'm trying to set up the Interchange 5.2 shopping cart
(icdevgroup.org) to use the CREATE SEQUENCE
functionality of pgsql properly and I'm having some
trouble. The table is called order_items and the
field that should sequence is called autonumber. The
Interchange DB config file looks like this for my
order_items table:

Database order_items DEFAULT_TYPE varchar(128)
Database order_items COLUMN_DEF "autonumber=int
char(12) NOT NULL PRIMARY KEY"

I've tried adding the following:

Database order_items CREATE_SEQUENCE
order_items_sequence START 2000
Database order_items COLUMN_DEF "id=int default
nextval('order_items_sequence')"

after reading these docs:

http://developer.postgresql.org/docs/postgres/sql-createsequence.html

but that doesn't seem to do it. This is the
Interchange error I get when trying to get the table
to sequence which may not be relevant here:

//admin/flex_editor DBD::Pg::st execute failed: ERROR:
Relation "1" does not exist at
/usr/local/interchange/lib/Vend/Table/DBI.pm line 942.

Does anyone have any tips for me?

- Grant


__________________________________
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail


From: "Joshua D(dot) Drake" <jd(at)commandprompt(dot)com>
To: Grant <emailgrant123b(at)yahoo(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: CREATE SEQUENCE
Date: 2004-08-03 04:38:32
Message-ID: 410F16C8.8090701@commandprompt.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-general

>
>
>
>but that doesn't seem to do it. This is the
>Interchange error I get when trying to get the table
>to sequence which may not be relevant here:
>
>//admin/flex_editor DBD::Pg::st execute failed: ERROR:
> Relation "1" does not exist at
>/usr/local/interchange/lib/Vend/Table/DBI.pm line 942.
>
>Does anyone have any tips for me?
>
>
>
Turn on statement logging in the postgresql.conf, restart postgresql and
rerun the error that way you
can get an actual query error which will help us debug it.

Sincerely,

Joshua D. Drake

>- Grant
>
>
>
>__________________________________
>Do you Yahoo!?
>Yahoo! Mail Address AutoComplete - You start. We finish.
>http://promotions.yahoo.com/new_mail
>
>---------------------------(end of broadcast)---------------------------
>TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>
>

--
Command Prompt, Inc., home of Mammoth PostgreSQL - S/ODBC and S/JDBC
Postgresql support, programming shared hosting and dedicated hosting.
+1-503-667-4564 - jd(at)commandprompt(dot)com - http://www.commandprompt.com
PostgreSQL Replicator -- production quality replication for PostgreSQL