DBAsupport.com Forums - Powered by vBulletin
Results 1 to 2 of 2

Thread: Cursor slowing down a process

  1. #1
    Join Date
    Jul 2000
    Location
    India
    Posts
    60
    Hi,

    i have written a procedure that uses a cursor. the cursor has a query contains a minus and a few joins. One of the tables has more than a million rows. the problem is that when i open the cursor and start the loop, it is fetching only some rows at a time (anywhere between 1 and 200) and then again fully scans this huge tables. This is causing a huge performance bottleneck. i tried using various joins (merge, NL, hash) but it goes the same way. I also have the right indexes. any suggestions ? can i change any parameter to make it fecth more rows per table scan ?

    Regards
    satish

  2. #2
    Join Date
    Nov 2000
    Location
    Baltimore, MD USA
    Posts
    1,339
    I have no idea what you are talking about with the 1 to 200 bit, but your first problem is the use of a CURSOR. This should be avoided if possible. If you provide the SQL, PL/SQL and EXPLAIN PLAN, and a little more description, maybe we can help you out.

    - Chris
    Christopher R. Long
    ChrisRLong@HotMail.Com
    But that's just my opinion. I could be wrong

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Click Here to Expand Forum to Full Width