SP_Cursor

  • Hi i have a SQL2005 stand edition which run some jobs from a Navision C5 Application, it's the C5 there is peforming the job, through ODBC agienst the database. The C5 is located local on the server.

    There are a Lots of SP_cursorFetch and SP_cursorClose, and when i run tuning advisoren its says that these commands cannot reference any tables, from my workload table which is made with the tuning table.

    Is there any body there have recommendation about this, the job takes very long time, 10 hours, on the SQL2000 it only took 5 hours.

  • Those sprocs are the ones that SQL Server runs behind the scenes for nearly every stored proc. The real problem is not those, but the query the query that runs for 10 hours. It needs to be checked/repaired for RBAR and other non-optimal code.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply