INSERT_RIGHT_REF_DEFAULT_VALUE

In B-compatible mode, the INSERT statement supports right-value reference. If a referenced column has a NOT NULL constraint and does not have a default value, its base value is used for calculation. If there is no basic value, the NULL value is used for calculation (array type or user-defined type). The basic values of the supported types are shown in Table 1.

Table 1 Type basic values

TypeBasic ValueDescription
int0
tinyint0
smallint0
integer0
binary_integer0
bigint0
booleanf
numeric0
decimal0
dec0
double precision0
float80
float0
char(n)""Note: When a character string is involved in calculation, the value type is converted based on built-in rules.
The length of the value stored by a fixed-length character string is the same as the specified length, and blank characters are filled (which may vary according to the storage mode).
varchar(n)""
varchar2(n)""
nchar(n)""Note: When a character string is involved in calculation, the value type is converted based on built-in rules.
The length of the value stored by a fixed-length character string is the same as the specified length, and blank characters are filled (which may vary according to the storage mode).
nvarchar2(n)""
nvarchar(n)""
date01-01-1970
time00:00:00
timestampCurrent timestamp
smalldatetimeThu Jan 01 00:00:00 1970
interval year@ 0
interval month@ 0
interval day@ 0
interval hour@ 0
interval minute@ 0
interval second@ 0
interval day to second@ 0
interval day to hour@ 0
interval day to minute@ 0
interval hour to minute@ 0
interval hour to second@ 0
interval minute to second@ 0
reltime@ 0
abstimeWed Dec 31 16:00:00 1969 PST
money$0.00
int4rangeempty
blobObject without data content
rawObject without data content
bytea\x
point(0,0)
lseg[(0,0),(0,0)]
box(0,0),(0,0)
path((0,0))
polygon((0,0))
circle<(0,0),0>
cidr0.0.0.0/32
inet0.0.0.0
macaddr00:00:00:00:00:00
BITObject without data content
BIT VARYINGObject without data content
UUID00000000-0000-0000-0000-000000000000
jsonnullThe data content is null.
jsonbnullThe data content is null.
int8rangeempty
numrangeempty
tsrangeempty
tstzrangeempty
daterangeempty
hll\x
SET""
tsvectorObject without data content
tsqueryObject without data content
HASH160000000000000000
HASH3200000000000000000000000000000000
enumThe first item
Feedback
编组 3备份
    openGauss 2024-05-19 00:42:09
    cancel