Re: posgres 12 bug (partitioned table)

From: Pavel Biryukov <79166341370(at)yandex(dot)ru>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: posgres 12 bug (partitioned table)
Date: 2020-08-11 18:31:52
Message-ID: 24981597170121@mail.yandex.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

<div>Sure,</div><div> </div><div>Entity Framework is an ORM for .Net (and .Net Core). It has different providers for different databases (NpgSql for Postgres). It uses Optimistic concurrency. The common use case is to use xmin as "concurrency token".</div><div> </div><div>In code we make "var e = new Entity();", "dbContext.Add(e)" and "dbContext.SaveChanges()" (smth like that), and EF Core constructs sql for us, classical ORM;</div><div> </div><div>When new row is inserted, EF makes an insert with "RETURNING xmin" to keep it as concurrency token for further updates (update is made like "where id = [id] AND xmin=[xmin]" to be sure the row hasn't been updated by other clients).</div><div> </div><div><a href="https://www.npgsql.org/efcore/modeling/concurrency.html">https://www.npgsql.org/efcore/modeling/concurrency.html</a></div><div> </div><div> </div><div> </div><div>-- <br />С уважением, Павел</div><div> </div><div> </div><div> </div><div>11.08.2020, 20:22, "Andres Freund" &lt;andres(at)anarazel(dot)de&gt;:</div><blockquote><p>Hi,<br /><br />On 2020-08-11 19:02:57 +0300, Pavel Biryukov wrote:</p><blockquote> I just want to point that Npgsql provider for .Net Core builds queries like<br /> that (RETURNING xmin) to keep track for concurrency.</blockquote><p><br />Could you provide a bit more details about what that's actually used<br />for?<br /><br />Regards,<br /><br />Andres</p></blockquote>

Attachment Content-Type Size
unknown_filename text/html 1.4 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Andres Freund 2020-08-11 18:39:40 Re: posgres 12 bug (partitioned table)
Previous Message Andres Freund 2020-08-11 18:06:59 Re: posgres 12 bug (partitioned table)

Browse pgsql-hackers by date

  From Date Subject
Next Message Jaime Casanova 2020-08-11 18:39:02 Re: EDB builds Postgres 13 with an obsolete ICU version
Previous Message Andres Freund 2020-08-11 18:06:59 Re: posgres 12 bug (partitioned table)