Tag Archives: sqlnewblogger

Add UNIQUE constraint WITH NOCHECK ? Not really …

Ever wanted to add a UNIQUE constraint WITH NOCHECK ? Maybe you had some duplicates in your data, fixed the code, but you cannot remove the duplicates, or maybe it’s a “temporary” thing.
Read more »

Automating restores for Ola Hallengren backup solution

While going through Brent Ozar’s 6-Month DBA Training Plan, I got myself a good challenge quite fast, after reading “Automating Restores” – to automate restores on backups taken using Ola Hallengren Backup Solution. Read more »

Passing a DataTable as table parameter from C# to stored procedures using table type

So may times I’ve seen useless loops to save many rows of data into a table, where data was captured in the front end part of the application. And sometimes, the row number was quite high – for example, where user was filtering some rows available to him, or imported from a data source like excel or access mdb file. Read more »

Safe exit from WHILE loop using ##global temp tables

Loops, SQL Server – these two things don’t go along as best friends, but every once in a WHILE, there’s no other way around. If I also add transactions, i surely want to have full control over it.
Read more »