summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'src/test')
-rw-r--r--src/test/regress/expected/domain.out7
-rw-r--r--src/test/regress/sql/domain.sql3
2 files changed, 4 insertions, 6 deletions
diff --git a/src/test/regress/expected/domain.out b/src/test/regress/expected/domain.out
index a67559129c..522c28121f 100644
--- a/src/test/regress/expected/domain.out
+++ b/src/test/regress/expected/domain.out
@@ -41,8 +41,7 @@ select * from basictest;
(2 rows)
-- check that domains inherit operations from base types
--- XXX shouldn't have to quote the constant here
-select testtext || testvarchar as concat, testnumeric + '42' as sum
+select testtext || testvarchar as concat, testnumeric + 42 as sum
from basictest;
concat | sum
-----------+--------
@@ -99,7 +98,7 @@ create table nulltest
, col4 dnull
);
INSERT INTO nulltest DEFAULT VALUES;
-ERROR: ExecInsert: Fail to add null value in not null attribute col3
+ERROR: Domain dnotnull does not allow NULL values
INSERT INTO nulltest values ('a', 'b', 'c', 'd'); -- Good
INSERT INTO nulltest values (NULL, 'b', 'c', 'd');
ERROR: Domain dnotnull does not allow NULL values
@@ -147,7 +146,7 @@ create table defaulttest
, col5 ddef1 NOT NULL DEFAULT NULL
, col6 ddef2 DEFAULT '88'
, col7 ddef4 DEFAULT 8000
- , col8 ddef5
+ , col8 ddef5
);
NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index 'defaulttest_pkey' for table 'defaulttest'
insert into defaulttest default values;
diff --git a/src/test/regress/sql/domain.sql b/src/test/regress/sql/domain.sql
index 4c2e7e31ac..9627870934 100644
--- a/src/test/regress/sql/domain.sql
+++ b/src/test/regress/sql/domain.sql
@@ -38,8 +38,7 @@ INSERT INTO basictest values ('88', 'haha', 'short', '123.1212'); -- Truncate
select * from basictest;
-- check that domains inherit operations from base types
--- XXX shouldn't have to quote the constant here
-select testtext || testvarchar as concat, testnumeric + '42' as sum
+select testtext || testvarchar as concat, testnumeric + 42 as sum
from basictest;
drop table basictest;