Re: Serial columns in PostgreSQL
[prev]
[thread]
[next]
[Date index for 2004/11/29]
JJ,
On Mon, 29 Nov 2004, JJ Merelo wrote:
> On Mon, 29 Nov 2004 11:07:21 -0500 (EST), Dana Hudes <dhudes@xxxxxx.xxxx> wrote:
> > RTFM. You have a sequence. Declare it and CDBI will Do The Right Thing.
>
> Thanks. Worked as a charm.
You are welcome.
>
> Question is, can't that be done automatically? There are tables that
> relate columns to sequences...
Class::DBI has no clue about Postgresql-specific stuff, nor should it.
serial is not standard SQL column type and it works different (or has
another name) in MySQL and in Oracle. CDBI is only supposed to deal in
ANSI SQL though the understanding and hooks for various kinds of
extensions, such as sequence, exist.
You can see if Class::DBI::Pg works
for you. Also check into Class::DBI::Loader .