Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > microsoft.public.sqlserver.programming > #31367
| From | Erland Sommarskog <esquel@sommarskog.se> |
|---|---|
| Newsgroups | microsoft.public.sqlserver.programming |
| Subject | Re: SQL job never ending |
| Date | 2020-04-22 21:07 +0200 |
| Organization | Erland Sommarskog |
| Message-ID | <XnsABA7D6F68C7EAYazorman@127.0.0.1> (permalink) |
| References | <4c1094b8-f2d2-4462-ae8b-9dba4f415616@googlegroups.com> |
(sstiakakis@gmail.com) writes: > It looks like it has to do with the change in step 9. However, by making > changes to any other step, eg in 2 where I update a column of the table > ITEMTRANSACTIONS I changed the calculation method and yet the job never > stuck to step 2. > What could be the reason of this never-ending job? > All sorts of reasons: 1) Long-running query plan. 2) Infinite loop. 3) Blocking. There may be more, but those are the ones that come to mind immeidately.. Since I don't know your tables or your code, I can't say what it might be, but you could use my beta_lockinfo to investigate whether there is any blocking. It will also show you the current statement. Running it repeatedly, can also some indication of the progress. http://www.sommarskog.se/sqlutil/beta_lockinfo.html If the job is running a loop of some sort, you may also have help of Lee Tudor's sp_sqltrace, which is also on my web site: http://www.sommarskog.se/sqlutil/sqltrace.html
Back to microsoft.public.sqlserver.programming | Previous | Next — Previous in thread | Find similar
SQL job never ending sstiakakis@gmail.com - 2020-04-22 09:29 -0700 Re: SQL job never ending Erland Sommarskog <esquel@sommarskog.se> - 2020-04-22 21:07 +0200
csiph-web