语法:
CREATE TYPE {schema.}name AS TABLE (name1 type1 {, name2 type2,...})
实列1:
CREATE TYPE tt_publishers AS TABLE (
publisher INTEGER,
name VARCHAR(50),
price DECIMAL,
cnt INTEGER
);
实列2:
CREATE type tt_year AS TABLE(
year varchar(4),
price decimal,
cnt integer
);
删除类型:
语法:DROP TYPE {schema.}name {CASCADE}