Please visit my New Blog http://www.sqlserverdba.co.cc/

April 22, 2008

How to Rebuild Index Since DBREINDEX will be discontinued after SQL 2005

Filed under: Performance Tuning — wwwtuneinin @ 1:38 pm

Microsoft Says:

SQL SERVER 2005 supports DBREINDEX but it will be deprecated in future versions.

So the options left out is to use DBCC INDEXDEFRAG which is applicable for online Re-indexing but the best solution is to use ALTER INDEX…

Simple Syntax:
ALTER INDEX PK_Employee_EmployeeID ON HumanResources.Employee
REBUILD;

Click below to access some of related articles:
http://www.sqlservercentral.com/scripts/62410/
http://blog.sqlauthority.com/2007/01/31/sql-server-reindexing-database-tables-and-update-statistics-on-tables/

April 18, 2008

Moving VL Table to a Different Filegroup - SQL2K5

Filed under: Performance Tuning — wwwtuneinin @ 5:29 pm

Server 2005, a new clause ‘MOVE TO’ was added to the ALTER TABLE command to allow for moving a table to a different filegroup. MOVE TO clause is used along with DROP CONSTRAINT clause in the ALTER TABLE syntax. When a primary key constraint or a constraint which created a clustered index is dropped, leaf level data rows of the clustered index are placed in non clustered table. In SQL Server 2005, when clustered index is dropped (By dropping constraint that created clustered index), one can move table to new filegroup or partition scheme in same transaction by using this new ‘MOVE TO’ option……

Click here to check the article

© 2007 Informe.com. Get Free Blog Hosting
Software tags powered by Software Informer
Powered by WordPress