• Ah yes, because the cursor is non-static it would have to check for updates to its data before the next fetch.

    If the sp is updating the data the cursor uses then this would be costly.

    I would therefore go beck to using a static cursor (ir it fetches all the data first then iterates through the recordset).

    I have been doing a test just iterating through 800K rows of a table, fetching data only...

    A static cursor took 8.5 secs to iterate through the whole lot

    A noral cursor took 17.5 secs

    and the table variable based approach took 30 secs!!!!

    This was all running on my machine not the server, I will maybe test same scenario on the server and report back...

    Cheers

    Bob