> > I think that when SERIAL is used, the sequence should be tied
> > inextricably to the table which created it, and it should be
hidden from
> > use for other purposes (perhaps similar to the way a toast table
is). If
> > you *want* to use a sequence across several tables, then you don't
use
> >
> I think that when SERIAL is used, the sequence should be tied
> inextricably to the table which created it, and it should be hidden from
> use for other purposes (perhaps similar to the way a toast table is). If
> you *want* to use a sequence across several tables, then you don't use
> SERIA
Tom Lane wrote:
> "Rod Taylor" <[EMAIL PROTECTED]> writes:
>
>>>What happens is the sequence is shared between several tables (eg.
>>>invoice numbers or something)
>>
>
>>You cannot accomplish this situation by strictly using the SERIAL
>>type.
>
>
> But Chris is correct that there are borderl
"Rod Taylor" <[EMAIL PROTECTED]> writes:
>> What happens is the sequence is shared between several tables (eg.
>> invoice numbers or something)
> You cannot accomplish this situation by strictly using the SERIAL
> type.
But Chris is correct that there are borderline cases where we might
do the w
> What happens is the sequence is shared between several tables (eg.
invoice
> numbers or something)
You cannot accomplish this situation by strictly using the SERIAL
type.
---(end of broadcast)---
TIP 5: Have you checked our extensive FAQ?
http:
> Currently serial is dumped as a sequence and appropriate default
> statement.
>
> With my upcoming dependency patch serials depend on the appropriate
> column. Drop the column (or table) and the sequence goes with it.
> The depencency information does not survive the pg_dump / restore
> process
Folks,
> No. IMHO, if we change the naming convention for serial sequences (which
> seems unlikely, except that it might be indirectly affected by changing
> NAMEDATALEN), then we'd *want* the new naming convention to take effect,
> not to have pg_dump scripts force an old naming convention to
]>
Cc: "Hackers List" <[EMAIL PROTECTED]>
Sent: Thursday, June 13, 2002 6:05 PM
Subject: Re: [HACKERS] Making serial survive pg_dump
> "Rod Taylor" <[EMAIL PROTECTED]> writes:
> > If we have sequences pick new names automatically, it may not pick
the
"Rod Taylor" <[EMAIL PROTECTED]> writes:
> If we have sequences pick new names automatically, it may not pick the
> same name after dump / restore as it had earlier -- especially across
> versions (see TODO entry).
> So don't we need a way to suggest the *right* name to SERIAL?
No. IMHO, if we c
e" <[EMAIL PROTECTED]>
To: "Rod Taylor" <[EMAIL PROTECTED]>
Cc: "Hackers List" <[EMAIL PROTECTED]>
Sent: Thursday, June 13, 2002 5:52 PM
Subject: Re: [HACKERS] Making serial survive pg_dump
> "Rod Taylor" <[EMAIL PROTECTED]> writes:
> &g
--
Rod
- Original Message -
From: "Tom Lane" <[EMAIL PROTECTED]>
To: "Rod Taylor" <[EMAIL PROTECTED]>
Cc: "Hackers List" <[EMAIL PROTECTED]>
Sent: Thursday, June 13, 2002 9:46 AM
Subject: Re: [HACKERS] Making serial survive pg_dump
>
sage -
From: "Tom Lane" <[EMAIL PROTECTED]>
To: "Rod Taylor" <[EMAIL PROTECTED]>
Cc: "Hackers List" <[EMAIL PROTECTED]>
Sent: Thursday, June 13, 2002 5:41 PM
Subject: Re: [HACKERS] Making serial survive pg_dump
> "Rod Taylor" <[
"Rod Taylor" <[EMAIL PROTECTED]> writes:
> Normally I'd agree, but I've found a few people who use normal
> sequence operations with serial sequences. That is, they track down
> the name and use it.
Sure. But what's this have to do with what pg_dump should emit?
regards
"Rod Taylor" <[EMAIL PROTECTED]> writes:
> Ok, keeping the setval is appropriate. Are there any problems with a
> SERIAL() implementation?
What for? The sequence name is an implementation detail, not something
we want to expose (much less let users modify).
regards, tom
"Rod Taylor" <[EMAIL PROTECTED]> writes:
> Store sequence information in the SERIAL creation statement:
> CREATE TABLE tab (col1 SERIAL(, ));
This is wrong because it loses the separation between schema and data.
I do agree that it would be nice if pg_dump recognized serial columns
and dumped the
Currently serial is dumped as a sequence and appropriate default
statement.
With my upcoming dependency patch serials depend on the appropriate
column. Drop the column (or table) and the sequence goes with it.
The depencency information does not survive the pg_dump / restore
process however as i
16 matches
Mail list logo