T-SQL Tuesday #48– Cloud Atlas
Welcome to this month’s (November 2013) edition of T-SQL Tuesday. For those not familiar this is rotating blog party that...
2013-11-05
688 reads
Welcome to this month’s (November 2013) edition of T-SQL Tuesday. For those not familiar this is rotating blog party that...
2013-11-05
688 reads
If you decide to park a database in read-only mode for a long period of time, go ahead and alter...
2013-11-13 (first published: 2013-11-05)
2,033 reads
In the last Tour of the Transaction Log we looked at how INSERT operations behave in the transaction log.
In this...
2013-11-04
550 reads
Upgrading from Power Pivot workbooks to SSAS Tabular models is usually a pretty seamless process. This is part of the...
2013-11-11 (first published: 2013-11-04)
1,849 reads
Yeah, I’m a couple of days late. Tough. My blog. My rules.
Speaking of rules. Speaker of the Month is chosen...
2013-11-04
662 reads
Two weeks ago I presented my session entitled “Squeezing Top Performance from Your Virtualized SQL Server” at the SQL PASS...
2013-11-12 (first published: 2013-11-04)
3,670 reads
These are a couple of stored procedures I wrote to help me with security research. Each sp returns three data...
2013-11-11 (first published: 2013-11-04)
1,863 reads
A couple of weeks ago I wrote a post dispelling the myth that the simple recovery model disables the transaction...
2013-11-04
952 reads
The 9th cumulative update release for SQL Server 2008 R2 Service Pack 2 is now available for download at the...
2013-11-04
1,001 reads
The 10th cumulative update release for SQL Server 2012 RTM is now available. Cumulative Update 10 contains all the hotfixes...
2013-11-04
850 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