Home » RDBMS Server » Performance Tuning » Who is faster Cursor or Recored
Who is faster Cursor or Recored [message #381522] Sat, 17 January 2009 11:23 Go to next message
eng.oracle
Messages: 48
Registered: December 2007
Member
Hello every one,
I have a procedure make sum calc.
and need to get data from main table.
Who is faster Cursor or Recored?
thank you
Re: Who is faster Cursor or Recored [message #381529 is a reply to message #381522] Sat, 17 January 2009 13:01 Go to previous messageGo to next message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
SQL.

Regards
Michel
Re: Who is faster Cursor or Recored [message #381539 is a reply to message #381522] Sat, 17 January 2009 23:13 Go to previous messageGo to next message
eng.oracle
Messages: 48
Registered: December 2007
Member
Thanks for replay.
But i can't understand u
Re: Who is faster Cursor or Recored [message #381543 is a reply to message #381539] Sun, 18 January 2009 00:23 Go to previous messageGo to next message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
As "u" didn't reply I understand you don't understand his answer.
I think the answer you got is as clear as your question.

Regards
Michel

[Updated on: Sun, 18 January 2009 00:24]

Report message to a moderator

Re: Who is faster Cursor or Recored [message #381546 is a reply to message #381522] Sun, 18 January 2009 00:33 Go to previous messageGo to next message
eng.oracle
Messages: 48
Registered: December 2007
Member
Who is faster using a cursor or record ?
-------------
declare
Cursor emp is 
  select e_id, e_name, ...
  from   emp
  where   conditons;
begin
 ..
end;


or
using record:

declare
  rec      emp%rowtype;
begin
 select  e_id, e_name, ...
 into    rec
  from   emp 
where   conditons;
..
end;


thanks
Re: Who is faster Cursor or Recored [message #381548 is a reply to message #381546] Sun, 18 January 2009 00:59 Go to previous messageGo to next message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
No difference.

Regards
Michel
Re: Who is faster Cursor or Recored [message #381553 is a reply to message #381548] Sun, 18 January 2009 01:10 Go to previous messageGo to next message
Littlefoot
Messages: 21823
Registered: June 2005
Location: Croatia, Europe
Senior Member
Account Moderator
The second one, though, might result with a TOO MANY ROWS error.
Re: Who is faster Cursor or Recored [message #381556 is a reply to message #381553] Sun, 18 January 2009 01:57 Go to previous message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
...or NO DATA FOUND.

Regards
Michel
Previous Topic: Performance Issue with FORALL BULK COLLECT
Next Topic: converting Normal Table to Partitioned Table
Goto Forum:
  


Current Time: Tue Nov 26 01:24:47 CST 2024