mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Backend support for autocommit removed, per recent discussions. The
only remnant of this failed experiment is that the server will take SET AUTOCOMMIT TO ON. Still TODO: provide some client-side autocommit logic in libpq.
This commit is contained in:
@ -190,7 +190,7 @@ WHERE t.a > 7;
|
||||
ERROR: dblink: no connection available
|
||||
-- put more data into our slave table, first using arbitrary connection syntax
|
||||
-- but truncate the actual return value so we can use diff to check for success
|
||||
SELECT substr(dblink_exec('dbname=regression','SET autocommit TO ''on'';INSERT INTO foo VALUES(10,''k'',''{"a10","b10","c10"}'')'),1,6);
|
||||
SELECT substr(dblink_exec('dbname=regression','INSERT INTO foo VALUES(10,''k'',''{"a10","b10","c10"}'')'),1,6);
|
||||
substr
|
||||
--------
|
||||
INSERT
|
||||
@ -205,7 +205,7 @@ SELECT dblink_connect('dbname=regression');
|
||||
|
||||
-- put more data into our slave table, using persistent connection syntax
|
||||
-- but truncate the actual return value so we can use diff to check for success
|
||||
SELECT substr(dblink_exec('SET autocommit TO ''on'';INSERT INTO foo VALUES(11,''l'',''{"a11","b11","c11"}'')'),1,6);
|
||||
SELECT substr(dblink_exec('INSERT INTO foo VALUES(11,''l'',''{"a11","b11","c11"}'')'),1,6);
|
||||
substr
|
||||
--------
|
||||
INSERT
|
||||
@ -231,7 +231,7 @@ FROM dblink('SELECT * FROM foo') AS t(a int, b text, c text[]);
|
||||
(12 rows)
|
||||
|
||||
-- change some data
|
||||
SELECT dblink_exec('SET autocommit TO ''on'';UPDATE foo SET f3[2] = ''b99'' WHERE f1 = 11');
|
||||
SELECT dblink_exec('UPDATE foo SET f3[2] = ''b99'' WHERE f1 = 11');
|
||||
dblink_exec
|
||||
-------------
|
||||
UPDATE 1
|
||||
@ -247,7 +247,7 @@ WHERE a = 11;
|
||||
(1 row)
|
||||
|
||||
-- delete some data
|
||||
SELECT dblink_exec('SET autocommit TO ''on'';DELETE FROM foo WHERE f1 = 11');
|
||||
SELECT dblink_exec('DELETE FROM foo WHERE f1 = 11');
|
||||
dblink_exec
|
||||
-------------
|
||||
DELETE 1
|
||||
|
Reference in New Issue
Block a user