citus/src/test/regress/expected/issue_7676.out

36 lines
981 B
Plaintext

-- https://github.com/citusdata/citus/issues/7676
CREATE TABLE test_ref_multiexpr (
id bigint primary key
, col_int integer
, col_bool bool
, col_text text
, col_timestamp timestamp
);
select create_reference_table('test_ref_multiexpr');
create_reference_table
---------------------------------------------------------------------
(1 row)
/* TODO how to ensure in test that 'now()' is correctly pre-executed */
insert into test_ref_multiexpr values (1, 1, true, 'one', now());
update test_ref_multiexpr
SET (col_timestamp)
= (SELECT now())
returning id, col_int, col_bool;
id | col_int | col_bool
---------------------------------------------------------------------
1 | 1 | t
(1 row)
update test_ref_multiexpr
SET (col_bool, col_timestamp)
= (SELECT true, now())
returning id, col_int, col_bool;
id | col_int | col_bool
---------------------------------------------------------------------
1 | 1 | t
(1 row)
DROP TABLE test_ref_multiexpr;