建立表:
CREATE TABLE sal_emp ( name text,pay_by_quarter integer[],schedule text[][] );
插入数据:
INSERT INTO sal_emp VALUES ('Bill',ARRAY[10000,11000,9000,13000],0); line-height:1.5!important">['meeting','lunch'],'training','presentation']]); Carol20000,25000,25000['breakfast','consulting''meeting',0); line-height:1.5!important">Frank]]);
查看:
pgsql=# SELECT * FROM sal_emp; name | pay_by_quarter | schedule -------+---------------------------+------------------------------------------- Bill | {10000,11000,0); line-height:1.5!important">9000,0); line-height:1.5!important">13000} | {{meeting,lunch},{training,presentation}} Carol 20000,0); line-height:1.5!important">25000,0); line-height:1.5!important">25000} | {{breakfast,consulting},{meeting,lunch}} Frank 10000} 3 rows) pgsql=#