Thread: Fw: Questions on 'Copy from' and functional indicies

Fw: Questions on 'Copy from' and functional indicies

From
"Seung-won Hwang"
Date:
 
 
Hi, I'm a newbie to Postgres DBMS and have following questions:
 
(1) When data is copied from the text file, are the attributes of the same object likely to stored nearby? That is, would it be more economical if I 'SELECT * blah' once and keep it in the memory to look up attributes (than issuing 'SELECT price WHERE', 'SELECT size WHERE' ... separately)?
 
(2) I'm impressed to see how fast building functional indicies is. Could anyone let me know what're underlying operations for building functional index? Is it just evaluating functions for all objects and building an index on it? Any secret of improving the performances?
 
(3) If building indices is that efficient, why not build indices for every function? (Well, data insertion/deletion will become more expensive if there are too many indices.. But assuming the data are not likely to change, any other disadvantages for this approach?)
 
Thanks!