Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: A job for two cursors?
weberm_at_polaris.net (Ubiquitous) w
> How is the best way to go about doing this?
As Daniel said.
INSERT INTO Itemized
SELECT
stuff
FROM Fee Detail
Itemized
WHERE join criteria
As a rule. Cursors as this by implication deals with data on a row-by-row level. This can have huge performance implications. Rather attempt to deal with a data set as oppose to a row. Cursor processing is difficult to scale when dealing with large volumes of data. Sure, bulk collection and pipe line tables are great PL/SQL features - but only when and where SQL cannot do the job.
Which brings me to the shortened version of the Oracle developer
mantra:
- do it in SQL
- if it cannot be done in SQL, use PL/SQL
And you will be amazed at what can be done in SQL. IMO many underestimate the power and capability of just plain Oracle SQL.
-- BillyReceived on Wed Oct 08 2003 - 06:43:41 CDT