| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.server -> CURSORS : SELECT * VERSUS SELECT only necessary columns
I wanto to tune my procedures. I have many independent procedures,
which check data in one table with many rows. E.g. the 1-st proceure
needs COL_1 and COL_2, 2-nd COL_1 and COL_3, 3-rd COL_1 and COL_5 etc.
from 1 row.
Sometimes all procedures are executed, sometimes only few of them - it
depends on the values in that rows.
Question:
What is better - If I use in cursors
1> SELECT * FROM table WHERE id=p_id..
and it will be in SQL Cache as 1 SQL statment, but every times many unnecessary columns will be selected
or
2> SELECT what I exactly need FROM table WHERE id=p_id..
but almost each procedure will have different SELECT
Thank you,
Jan Received on Thu Dec 06 2001 - 09:45:59 CST
![]() |
![]() |