Thread: mvcc.sgml make up

mvcc.sgml make up

From
Volkan YAZICI
Date:

Attachment

Re: mvcc.sgml make up

From
Peter Eisentraut
Date:
Volkan YAZICI wrote:
[nothing]

Please explain why you think this change is useful.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

Re: mvcc.sgml make up

From
Volkan YAZICI
Date:
On 12/5/05, Peter Eisentraut <peter_e@gmx.net> wrote:
> Please explain why you think this change is useful.

I've read related part of the documentation 4-5 times and couldn't
figure out the main difference between phantom and nonrepeatable read.
At last, I've googled and found an explanation in some Oracle
documentation. You know, not only hackers reading PostgreSQL docs.

For the second mvcc.sgml edit, there's a huge difference between "two
successive SELECT commands" and "two successive same SELECT commands".

Re: mvcc.sgml make up

From
Tom Lane
Date:
Volkan YAZICI <volkan.yazici@gmail.com> writes:
> For the second mvcc.sgml edit, there's a huge difference between "two
> successive SELECT commands" and "two successive same SELECT commands".

Indeed, and I would argue that your proposed change is exactly wrong.
For instance,
    SELECT * FROM foo WHERE col > 4;
    SELECT * FROM foo WHERE col > 5;
Under READ COMMITTED, the second SELECT may retrieve rows not found by
the first, which would be impossible under SERIALIZABLE mode.

            regards, tom lane

Re: mvcc.sgml make up

From
Volkan YAZICI
Date:
On 12/5/05, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> SELECT * FROM foo WHERE col > 4;
> SELECT * FROM foo WHERE col > 5;

Ofcourse two different SELECT queries are (probably) gonna return
different results. If this is the point you want to underline in the
documentation, just rip that sentence off.

From the documentation:
  «Notice that two successive SELECT commands can see different data,
  even though they are within a single transaction, if other transactions
  commit changes during execution of the first SELECT.»
It's not interesting to see "two different SELECT queries" will return
different results. As I understand from the above statement, the point
in here is that the "same SELECT queries" may return different results
too.

Anyway, this what I understand from documentation. I just tried to
clarify the argument. If most of you think this just confuses more and
wrong, than just ignore the patch.

Re: mvcc.sgml make up

From
Tom Lane
Date:
Volkan YAZICI <volkan.yazici@gmail.com> writes:
> On 12/5/05, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> SELECT * FROM foo WHERE col > 4;
>> SELECT * FROM foo WHERE col > 5;

> Ofcourse two different SELECT queries are (probably) gonna return
> different results. If this is the point you want to underline in the
> documentation, just rip that sentence off.

The point is that a row with (say) col = 10 might appear or disappear
or change between the two queries.  Whether the queries are formally
identical doesn't affect that.

            regards, tom lane