SQL SERVER – Simple Example of Cursor – Sample Cursor Part 2

I have recently received email that I should update SQL SERVER – Simple Example of Cursor with example of AdventureWorks database. Simple Example of Cursor using AdventureWorks Database is listed here. USE AdventureWorks GO DECLARE @ProductID INT DECLARE @getProductID CURSOR SET @getProductID = CURSOR FOR SELECT ProductID FROM Production.Product OPEN @getProductID FETCH…
Read More

SQLAuthority News – Best Articles on SQLAuthority.com

SQL SERVER – Cursor to Kill All Process in Database SQL SERVER – Find Stored Procedure Related to Table in Database – Search in All Stored procedure SQL SERVER – Shrinking Truncate Log File – Log Full SQL SERVER – Simple Example of Cursor SQL SERVER – UDF – Function…
Read More

SQL SERVER – Difference Between EXEC and EXECUTE vs EXEC() – Use EXEC/EXECUTE for SP always

What is the difference between EXEC and EXECUTE? They are the same. Both of them executes stored procedure when called as EXEC sp_help GO EXECUTE sp_help GO I have seen enough times developer getting confused between EXEC and EXEC(). EXEC command executes stored procedure where as EXEC() function takes dynamic…
Read More