Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2012 Forums
 Transact-SQL (2012)
 How WAITFOR really work?

Author  Topic 

SQL_Prodigy
Starting Member

4 Posts

Posted - 2014-01-17 : 02:30:01
I have following query:

SELECT * FROM Table t1
WAITFOR DELAY '00:00:10'

Question is: Did SQL Server immediately executes query and keep result in RAM for 10 seconds, and then do something with it, or SQL Server is waiting for 10 seconds, and then really executes query?

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2014-01-17 : 02:50:24
It will just wait for prescribed time after executing the SELECT in the above case

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page
   

- Advertisement -