Possible bug in 7.4.5

From: Devrim GUNDUZ <devrim(at)gunduz(dot)org>
To: pgsql-bugs(at)PostgreSQL(dot)org
Subject: Possible bug in 7.4.5
Date: 2004-10-06 09:10:28
Message-ID: Pine.LNX.4.61.0410061158070.9727@emo.org.tr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

I'm using 7.4.5 on a test platform and had a weird behaviour. Here is the
case:

test=# CREATE TABLE t1 (s_no int2 PRIMARY KEY,a varchar(10));
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "t1_pkey"
for table "t1"
test=# CREATE TABLE t2 (s_no int2, x char(2), CONSTRAINT
s_no_exists FOREIGN KEY(s_no) REFERENCES t1 ON UPDATE CASCADE);
test=# INSERT INTO t1 VALUES ('20','test1');
test=# INSERT INTO t1 VALUES ('21','test2');
test=# BEGIN ;
test=# INSERT INTO t2 VALUES ('20','as');
test=# COMM;
ERROR: syntax error at or near "COMM" at character 1
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
test=# COMMIT ;
COMMIT
^^^^^^^^^^^^^^^

Shouldn't it say "ERROR: current transaction is aborted, commands
ignored until end of transaction block" after the commit?

Since COMMIT was executed 'successfully', I thought that t2 has a row
inside, but:

test=# SELECT * from t2 ;
s_no | x
- ----------+---
(0 rows)

Am I missing something, or is it a bug? I can't reproduce it in 8.0beta2.

Regards,
- --
Devrim GUNDUZ
devrim~gunduz.org devrim.gunduz~linux.org.tr
http://www.tdmsoft.com
http://www.gunduz.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQFBY7aKtl86P3SPfQ4RAqUjAKDozbghdFKr0nHoO6uHZSoYQcl9FwCdEbtP
uhbCpVAqfhzijJG+g/XDO1Q=
=ROu9
-----END PGP SIGNATURE-----

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message PostgreSQL Bugs List 2004-10-06 11:50:51 BUG #1280: Unexpected EOF at Client Connection
Previous Message Alexander Zhiltsov 2004-10-06 06:55:13 Re: Bug in PostrgeSQL 8.0beta