Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Stored function 1000 times slower than in SQL*PLUS (??)
compere_at_mail.nacamar.de (Jaques Compere) wrote:
> PROBLEM: An INSERT-Statement within a function of a stored
> PL/SQL-package takes much more time (2 hours) than the same
> INSERT-Statement executed in SQL*PLUS (5 seconds).
>
> The INSERT is made up by an SELECT GROUP BY that contains a join of 3
> tables (including the target-table for the insert).
>
> If the tables contain between 10 000 and 30 000 records the
> PL/SQL-procedure runs for hours. If the tables only contain 1 record
> it takes only a few seconds.
> Strangely the same insert executed in SQL*PLUS is finished in only a
> few seconds independent of the number of records in the tables.
>
> Any infos or comments are appreciated!
>
> ghampton_at_levi.com
>
Please tell your operating system and Oracle Server version...
Thanks,
-- Luis Santos Relacional Consultoria Rio de Janeiro - BrazilReceived on Tue Dec 24 1996 - 00:00:00 CST