Greg Stark <[email protected]> writes:
> However then I started thinking about this case and wondered if it
> wouldn't be possible to optimize. One of the suggested optimizations
> was to look at using TRUNCATE. But I wonder why it's necessary to use
> a dedicated command. Shouldn't it be possible for the system to notice
> this situation and do effectively the same thing itself?
Not unless you'd like DELETE to always acquire exclusive lock...
> There are a couple problems with the way I've described this idea
> here.
Precisely because of the lack of lock.
regards, tom lane
--
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers