Inheritance
От | anil |
---|---|
Тема | Inheritance |
Дата | |
Msg-id | 36565BF9.10873260@awcoldstream.com обсуждение исходный текст |
Список | pgsql-sql |
Hi All, I have a fields for customer: cusId int4 - customer ID Unique number cusName text - Customer Name cusPrice int4 - Customer pricing scheme cusAdd text - Customer Address cusCity text - customer city cusProv text - Customer city cusZip text - Customer zip I am using first three fields on a order window lot and I use all fields on the customer information Window. if i create two tables:: table scustomer -> (cusid int4 primary key, cusName text, cus cusPrice) lcustomer -> (cusAdd text , cusCity text, cusProv text ,cusZip text ) inherits (scustomer) so I could use select cusId,cusName,cusPrice from lcustomer; or select * from from scustomer*; which query is going to faser???? or is there anyway that I insert some rows into lcustomer table and get result on corrosponding fields on scustomer table?? I have tried this: insert into lcustomer(1234,'My customer',10,'Myaddress',Mycity','Myprov','Myzip'); select * from lcustomer; 1234 | My customer | 10 | Myaddress | Mycity | Myprov | Myzip select * from scustomer; zero rows; select * from scustomer*; 1234 | My customer | 10 what do you mean by - Append (cost=0.0 size=0 width=0) on the out put of explain select * from scustomer*; Thank you Anil
В списке pgsql-sql по дате отправления: