Job SQL: script function changes during the execution of a job RRS feed

  • Domanda

  • Hello everyone,
    I have a problem to me inexplicable.
    Got a job running overnight on my MS SQL Server 2005 db engine that performs calculations and then save the results on a table.
    The process sometimes slows down in a frightening, from 20 minutes at best 19-20 hours. I limited the problem to a function only, but also

    completely rewriting it changes nothing.
    Inexplicably if launching a script that changes the function while the process is running, the function is faster and the process is successful.
    Obviously the script editing function is completely irrelevant to the calculation (ie add the WHERE clause of a SELECT "and 2 = 2).

    Does anyone have ideas?

    giovedì 24 giugno 2010 10:23