@@ -276,18 +276,18 @@ DROP TABLE temporal3;
276276-- test PK inserts
277277--
278278-- okay:
279- INSERT INTO temporal_rng VALUES ('[1,1] ', daterange('2018-01-02', '2018-02-03'));
280- INSERT INTO temporal_rng VALUES ('[1,1] ', daterange('2018-03-03', '2018-04-04'));
281- INSERT INTO temporal_rng VALUES ('[2,2] ', daterange('2018-01-01', '2018-01-05'));
282- INSERT INTO temporal_rng VALUES ('[3,3] ', daterange('2018-01-01', NULL));
279+ INSERT INTO temporal_rng(id, valid_at) VALUES ('[1,2) ', daterange('2018-01-02', '2018-02-03'));
280+ INSERT INTO temporal_rng(id, valid_at) VALUES ('[1,2) ', daterange('2018-03-03', '2018-04-04'));
281+ INSERT INTO temporal_rng(id, valid_at) VALUES ('[2,3) ', daterange('2018-01-01', '2018-01-05'));
282+ INSERT INTO temporal_rng(id, valid_at) VALUES ('[3,4) ', daterange('2018-01-01', NULL));
283283-- should fail:
284- INSERT INTO temporal_rng VALUES ('[1,1] ', daterange('2018-01-01', '2018-01-05'));
284+ INSERT INTO temporal_rng(id, valid_at) VALUES ('[1,2) ', daterange('2018-01-01', '2018-01-05'));
285285ERROR: conflicting key value violates exclusion constraint "temporal_rng_pk"
286286DETAIL: Key (id, valid_at)=([1,2), [2018-01-01,2018-01-05)) conflicts with existing key (id, valid_at)=([1,2), [2018-01-02,2018-02-03)).
287- INSERT INTO temporal_rng VALUES (NULL, daterange('2018-01-01', '2018-01-05'));
287+ INSERT INTO temporal_rng(id, valid_at) VALUES (NULL, daterange('2018-01-01', '2018-01-05'));
288288ERROR: null value in column "id" of relation "temporal_rng" violates not-null constraint
289289DETAIL: Failing row contains (null, [2018-01-01,2018-01-05)).
290- INSERT INTO temporal_rng VALUES ('[3,3] ', NULL);
290+ INSERT INTO temporal_rng(id, valid_at) VALUES ('[3,4) ', NULL);
291291ERROR: null value in column "valid_at" of relation "temporal_rng" violates not-null constraint
292292DETAIL: Failing row contains ([3,4), null).
293293--
@@ -303,8 +303,8 @@ CREATE TABLE temporal3 (
303303);
304304INSERT INTO temporal3 (id, valid_at, id2, name)
305305 VALUES
306- ('[1,1] ', daterange('2000-01-01', '2010-01-01'), '[7,7] ', 'foo'),
307- ('[2,2] ', daterange('2000-01-01', '2010-01-01'), '[9,9] ', 'bar')
306+ ('[1,2) ', daterange('2000-01-01', '2010-01-01'), '[7,8) ', 'foo'),
307+ ('[2,3) ', daterange('2000-01-01', '2010-01-01'), '[9,10) ', 'bar')
308308;
309309DROP TABLE temporal3;
310310--
@@ -331,12 +331,12 @@ CREATE TABLE temporal_partitioned (
331331 name text,
332332CONSTRAINT temporal_paritioned_pk PRIMARY KEY (id, valid_at WITHOUT OVERLAPS)
333333) PARTITION BY LIST (id);
334- CREATE TABLE tp1 PARTITION OF temporal_partitioned FOR VALUES IN ('[1,1] ', '[2,2] ');
335- CREATE TABLE tp2 PARTITION OF temporal_partitioned FOR VALUES IN ('[3,3] ', '[4,4] ');
336- INSERT INTO temporal_partitioned VALUES
337- ('[1,1] ', daterange('2000-01-01', '2000-02-01'), 'one'),
338- ('[1,1] ', daterange('2000-02-01', '2000-03-01'), 'one'),
339- ('[3,3] ', daterange('2000-01-01', '2010-01-01'), 'three');
334+ CREATE TABLE tp1 PARTITION OF temporal_partitioned FOR VALUES IN ('[1,2) ', '[2,3) ');
335+ CREATE TABLE tp2 PARTITION OF temporal_partitioned FOR VALUES IN ('[3,4) ', '[4,5) ');
336+ INSERT INTO temporal_partitioned(id, valid_at, name) VALUES
337+ ('[1,2) ', daterange('2000-01-01', '2000-02-01'), 'one'),
338+ ('[1,2) ', daterange('2000-02-01', '2000-03-01'), 'one'),
339+ ('[3,4) ', daterange('2000-01-01', '2010-01-01'), 'three');
340340SELECT * FROM temporal_partitioned ORDER BY id, valid_at;
341341 id | valid_at | name
342342-------+-------------------------+-------
@@ -366,12 +366,12 @@ CREATE TABLE temporal_partitioned (
366366 name text,
367367CONSTRAINT temporal_paritioned_uq UNIQUE (id, valid_at WITHOUT OVERLAPS)
368368) PARTITION BY LIST (id);
369- CREATE TABLE tp1 PARTITION OF temporal_partitioned FOR VALUES IN ('[1,1] ', '[2,2] ');
370- CREATE TABLE tp2 PARTITION OF temporal_partitioned FOR VALUES IN ('[3,3] ', '[4,4] ');
371- INSERT INTO temporal_partitioned VALUES
372- ('[1,1] ', daterange('2000-01-01', '2000-02-01'), 'one'),
373- ('[1,1] ', daterange('2000-02-01', '2000-03-01'), 'one'),
374- ('[3,3] ', daterange('2000-01-01', '2010-01-01'), 'three');
369+ CREATE TABLE tp1 PARTITION OF temporal_partitioned FOR VALUES IN ('[1,2) ', '[2,3) ');
370+ CREATE TABLE tp2 PARTITION OF temporal_partitioned FOR VALUES IN ('[3,4) ', '[4,5) ');
371+ INSERT INTO temporal_partitioned(id, valid_at, name) VALUES
372+ ('[1,2) ', daterange('2000-01-01', '2000-02-01'), 'one'),
373+ ('[1,2) ', daterange('2000-02-01', '2000-03-01'), 'one'),
374+ ('[3,4) ', daterange('2000-01-01', '2010-01-01'), 'three');
375375SELECT * FROM temporal_partitioned ORDER BY id, valid_at;
376376 id | valid_at | name
377377-------+-------------------------+-------