SQL SERVER – 2005 – Explanation and Script for Online Index Operations – Create, Rebuild, Drop

SQL Server 2005 Enterprise Edition supports online index operations. Index operations are creating, rebuilding and dropping indexes. The question which I receive quite often – what is online operation? Is online operation is related to web, internet or local network? Online operation means when online operations are happening the database…
Read More

SQL SERVER – 2005 – Difference and Similarity Between NEWSEQUENTIALID() and NEWID()

NEWSEQUENTIALID() and NEWID() both generates the GUID of datatype of uniqueidentifier. NEWID() generates the GUID in random order whereas NEWSEQUENTIALID() generates the GUID in sequential order. Let us see example first demonstrating both of the function. USE AdventureWorks; GO ----Create Test Table for with default columns values CREATE TABLE TestTable…
Read More

SQL SERVER – Insert Data From One Table to Another Table – INSERT INTO SELECT – SELECT INTO TABLE

Following three questions are many times asked on this blog. How to insert data from one table to another table efficiently? How to insert data from one table using where condition to another table? How can I stop using cursor to move data from one table to another table? There…
Read More