创建自定义类型
create type room_capacity_type as object(
auditorium_setting integer,
table_setting integer,
standing_room_setting integer)
表中使用
create table t4(lot room_capacity_type)
插入值
insert into t4(lot) values(room_capacity_type(10,10,10));
访问
select
a.lot.auditorium_setting,
a.lot.table_setting,
a.lot.standing_room_setting
from t4 a;