why is this taking forever? going on 6 hours

  • select max(last_execution_time) from sys.dm_exec_query_stats s cross apply sys.dm_exec_query_plan (s.plan_handle) p

    where object_name(p.objectid, db_id('leadmaster')) = 'Alert_ESMTranmission'

    union

    select max(last_execution_time) from sys.dm_exec_query_stats s cross apply sys.dm_exec_query_plan (s.plan_handle) p

    where object_name(p.objectid, db_id('leadmaster')) = 'AlertExtactTarget'

    im running 28 other stored procedures i only am showing two of them

  • the answer is basically the cache is just that big

    mabye there is a better way of doing this but its 2 minutes per statment for my server, for a total 5 hours to finish and i guess its acceptable cause i only need to run it once

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

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