Fun with sp_rename
Currently the only way to rename objects in SQL Server is to use sp_rename. Although that may be changing in...
2018-01-11
1,545 reads
Currently the only way to rename objects in SQL Server is to use sp_rename. Although that may be changing in...
2018-01-11
1,545 reads
Link Below:
How to Change the File Extension for a Data File
In general, the file extensions that we use for SQL Server data files are MDF (Primary Data File), NDF...
2018-01-11
17 reads
Link Below:
How to Change the File Extension for a Data File
In general, the file extensions for our SQL Data Files...
2018-01-11
404 reads
Link Below:
Changing the Path for the Master Database
This article will show how we can move the master database to a new location.
The ALTER DATABASE command would work for moving...
2018-01-11
15 reads
Link Below:
Changing the Path for the Master Database
This article will show how we can move the master database to a...
2018-01-11
360 reads
I ran into an issue recently where I couldn’t get a Windows login to work with some application software. This...
2018-01-10
442 reads
Have you ever downloaded a script from an internet site, only to find that there are extra blank lines between...
2018-01-10
461 reads
A year ago, I wrote in a post that cloud computing is just someone else’s data center. I was wrong. Whether...
2018-01-10
372 reads
Awhile back, if you are on Twitter, you can probably recall my ranting about the 949 indexes I was reviewing....
2018-01-10
1,725 reads
This post is by Chris Gibson
I recently wanted to exclude some temporary SQL databases from being discovered by our SCOM...
2018-01-10
1,370 reads
Creating a Fabric workspace takes about 30 seconds. Restructuring workspaces after people have built...
By Steve Jones
It’s a small change, but a handy one. Flyway Desktop (FWD) now includes the...
By Steve Jones
Software is hard. While I love our Lucid Gravity, I realize that they are...
Comments posted to this topic are about the item Adding new column with DEFAULT...
Comments posted to this topic are about the item Advanced Deployment Scenarios: Stairway to...
Comments posted to this topic are about the item You Need a DBA Pipeline
Which number did the two COUNT(*) return:
DROP TABLE IF EXISTS #tmp CREATE TABLE #tmp (id INT NOT NULL) INSERT INTO #tmp (id) SELECT gs.value FROM GENERATE_SERIES(1, 5) AS gs ALTER TABLE #tmp ADD my_value INT NOT NULL CONSTRAINT df_tmp_my_value DEFAULT 1 SELECT COUNT(*) FROM #tmp AS t WHERE my_value = 1 ALTER TABLE #tmp DROP CONSTRAINT df_tmp_my_value ALTER TABLE #tmp ADD CONSTRAINT df_tmp_my_value DEFAULT 2 FOR my_value SELECT COUNT(*) FROM #tmp AS t WHERE my_value = 1See possible answers