November 17th, 2003, 02:30 PM
Join Date: Nov 2003
Time spent in forums: < 1 sec
Reputation Power: 0
Insert Proc Optimization
I'm pretty new to creating Procs in Oracle, I'm coming from SQL Server. I have a procedure that is taking a very long time to run. It loops through about 15 insert statement for the amount of days between two dates.
My question is,
would the proc be better optimized using a loop like follows:
FOR v_data IN (
INSERT INTO TABLEA (EMP_GRP_NODE_SK, DESCR, LABEL)
VALUES (v_data.Col1, v_data.Col2, v_data.Col3);
or would it be better to just run the insert statement as follows:
INSERT INTO TableA(Col1, Col2,Col3)
I'd appreciate any help, and or suggestions.