You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is of course a matter of preference, but I would change the script that creates the index to just check if it exists, and delete it if it does. After a while, you might delete the script altogether, of course, if you know that no deployment has the index anymore.
Say you had a script that was (SQL server syntax):
DROP INDEX IF EXISTS IX_Table_Column ON [schema].[Table]
CREATE NONCLUSTERED INDEX [IX_Table_Column]
ON [schema].[Table]
(
[Column1],
[Column2]
)
GO
I would change the script to be just:
DROP INDEX IF EXISTS IX_Table_Column ON [schema].[Table]
And then, after a while, when you know this change has been deployed to all DBs containing the index, I would delete the file altogether.
Hello!
I want to manage indexes based on
index
folder. I will add file based on template provided inAnytimescripts
page(https://github.com/chucknorris/roundhouse/wiki/Anytimescripts).Could you please suggest how to remove index in a good way?
Should I have file with delete index statement or I can just remove the index file?
The text was updated successfully, but these errors were encountered: