Friday, January 6, 2012

Reenable sql server index

SELECT
'ALTER INDEX ' + I.name + ' ON ' + T.name + ' REBUILD ' FROM SYS.indexes I INNER JOIN SYS.tables T ON I.object_id = T.object_idWHERE I.name LIKE 'IX%'

No comments:

Post a Comment