After issuing a query or running a stored procedure in SQL Server 2005, is there a way to know when a query/stored procedure will complete.

e.g. In file manager, when a file is copied it will mention approximately, how long it will take to complete. In oracle, looking at longops, it can be determined how much time(approximation) the query will take to complete.

Maybe I'm wrong, but I took a look at the data returned by the view in my system and it looks like it holds statistics for sql handles of queries and procedure already executed.If you execute the same procedure or query you could look in the dm views and guess the new execution times.

You can make something of an educated guess if, over time, you establish a relationship between 'query cost' as reported in the execution plan, and the actual time it took to execute. For example, I have an 8 proc server with 32GB RAM, 2.2Ghz cpu, on top of a small SAN configured to provide a max disk IO of 18000 Ops/sec. I have established that a query cost of 13000 units equates to roughly 5 minutes if there are no other competing operations. Note that this relationship will not be the same on any server and DB that is not exactly the same in every way.The bottom line is that if you can establish an approximate relationship you will, under a fairly strict set of conditions, be able to predict the approximate execution time and by extension, the approximate time to complete at any point during execution. However, if you had to bet your life or job on when it would complete...don't.