aldem-pikedev@aldem.net wrote:
I am preparing to use Postgres in my app, found the following strange behavior:
---snip--- Sql.Sql db = Sql.Sql("pgsql://localhost", "test", "test", "test");
db->query("BEGIN"); db->query("INSERT INTO requests (SvTrId) VALUES ('lala')"); catch(db->query("INSERT INTO requests (SvTrId) VALUES ('lala')")); db->query("INSERT INTO requests (SvTrId) VALUES ('juju')"); db->query("ROLLBACK"); ---snip---
Database is opened, row with 'lala' is inserted, second query (obviously) fails as SvTrId is the primary key, but row with 'juju' is inserted *and* appears in the database - i.e. the transaction is *committed*!
Did anyone ever look into this? I was wading through some backlog mailinglist archives and came across this gem. I'm guessing nobody did, in which case I'll check and patch it.