Re: [HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Tom Lane
Steve Singer writes: > I will look at addressing this in an updated patch. I've nearly finished revising the patch already, don't worry about it. >> Should currval really be used after a failed transaction ? Right now, we can >> have a value that has been generated inside a rollbacked transactio

Re: [HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Steve Singer
On 10-11-17 03:00 PM, Marc Cousin wrote: The Wednesday 17 November 2010 19:41:19, Tom Lane wrote : Marc Cousin writes: - Does the feature work as advertised? Yes. It works consistently, isn't fooled by savepoints or multiple serials in a table, or concurrent transactions I think there's a r

Re: [HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Marc Cousin
The Wednesday 17 November 2010 19:41:19, Tom Lane wrote : > Marc Cousin writes: > >>> - Does the feature work as advertised? > >>> > >>> Yes. It works consistently, isn't fooled by savepoints or multiple > >>> serials in a table, or concurrent transactions > > I think there's a rather nasty prob

Re: [HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Tom Lane
Marc Cousin writes: >>> - Does the feature work as advertised? >>> >>> Yes. It works consistently, isn't fooled by savepoints or multiple >>> serials in a table, or concurrent transactions I think there's a rather nasty problem here, which is what to do with the cached nextval/currval state. As

Re: [HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Marc Cousin
The Wednesday 17 November 2010 15:50:36, Jaime Casanova wrote : > On Wed, Nov 17, 2010 at 8:13 AM, Marc Cousin wrote: > > - Does the feature work as advertised? > > > > Yes. It works consistently, isn't fooled by savepoints or multiple > > serials in a table, or concurrent transactions > > i hav

Re: [HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Jaime Casanova
On Wed, Nov 17, 2010 at 8:13 AM, Marc Cousin wrote: > > - Does the feature work as advertised? > > Yes. It works consistently, isn't fooled by savepoints or multiple serials > in a table, or concurrent transactions > i haven't tested this nor readed the patch but i wondering what happens in the p

[HACKERS] Review: rollback sequence reset for TRUNCATE ... RESTART IDENTITY

2010-11-17 Thread Marc Cousin
Hi, Here is my review of 'rollback sequence reset for TRUNCATE ... RESTART IDENTITY' patch. - Is the patch in context diff format? It's in git diff format. I guess it's OK ? - Does it apply cleanly to the current git master? Yes - Does it include reasonable tests, necessary doc patches, etc? Do