Let’s just say, it wasn’t a pretty piece of script.
I ran into some ‘Message 823’ issues on my development DB, and upon running DBCC CheckDB() I saw that my indexes were the ones throwing the errors. I got this handy cursor from SQL Server Performance, and decided to save it here for me, and for you, so that I don’t have to search for […]
I will make this short and sweet for you. If there is something you want to do to all tables in your database, there is a command for you. I will demonstrate, watch my hands because I cheat. To add a column to every table: exec sp_msforeachtable ‘alter table ? add intGoat int NULL’ To […]
I’m going to tell you a little secret. Come, sit closer. You know your running chart for every other dashboard, showing the SUM / Average / Top / Least / etc. of Sales / New customers / Quotes / etc. for the last… 1 hour / 1 day / 1 week / 4 weeks / […]
By definition SQL Server uses the install directory to store its data, unless you’ve taken care of that aspect during installation. The default directory is C:\Program Files\Microsoft SQL Server\MSSQL\MSSQL\DATA Initially, that solution is absolutely fine, until you realize that SQL Server and its rapidly expanding databases are slowly eating up the disk space dedicated for […]
And it runs, and it’s bug free, and it succeeds, and it schedules, and it runs again, so with other words: IT’S DONE.