BEGIN/END question ...

From: The Hermit Hacker <scrappy(at)hub(dot)org>
To: pgsql-general(at)postgresql(dot)org
Subject: BEGIN/END question ...
Date: 2000-01-21 18:01:41
Message-ID: Pine.BSF.4.21.0001211358420.23487-100000@thelab.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


In v6.5.3, if I do:

BEGIN;
SELECT * FROM <table> WHERE <datefield> < now();
DELETE FROM <table> WHERE <datafield> < now();
END;

and, between the SELECT/DELETE, someone inserts data into the table that
matches the WHERE clause, will the DELETE pick that up also?

I know its an odd question, but if I have any faint understanding of MVCC,
it won't, because when I issue the BEGIN/SELECT, it will "timestamp" my
transaction and only affect those tuples that were in existence when I
started ...

... but I want to confirm :)

Marc G. Fournier ICQ#7615664 IRC Nick: Scrappy
Systems Administrator @ hub.org
primary: scrappy(at)hub(dot)org secondary: scrappy(at){freebsd|postgresql}.org

Browse pgsql-general by date

  From Date Subject
Next Message Ed Bras 2000-01-21 18:47:07 RE: stat failed on /usr/lib/pgsql/plpgsql.so; no file or directory
Previous Message Culberson, Philip 2000-01-21 16:13:37 RE: [GENERAL] Too many open files...