mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-13 01:47:05 +08:00
now all that is tested is Rod Taylor's recent addition to allow
this syntax:
UPDATE ... SET <col> = DEFAULT;
If anyone else would like to add more UPDATE tests, go ahead --
I just wanted to write a test for the above functionality, and
couldn't see an existing test that it would be appropriate
to add to.
Neil Conway
19 lines
320 B
SQL
19 lines
320 B
SQL
--
|
|
-- UPDATE ... SET <col> = DEFAULT;
|
|
--
|
|
|
|
CREATE TABLE update_test (
|
|
a INT DEFAULT 10,
|
|
b INT
|
|
);
|
|
|
|
INSERT INTO update_test VALUES (5, 10);
|
|
INSERT INTO update_test VALUES (10, 15);
|
|
|
|
SELECT * FROM update_test;
|
|
|
|
UPDATE update_test SET a = DEFAULT, b = DEFAULT;
|
|
|
|
SELECT * FROM update_test;
|
|
|
|
DROP TABLE update_test; |