A pattern to do beginning of period calculations.
Beginning of period calculations are common things. Rolling month reports, queries to pull everything from last month etc require beginning...
2013-11-20
777 reads
Beginning of period calculations are common things. Rolling month reports, queries to pull everything from last month etc require beginning...
2013-11-20
777 reads
First, lets understand what the types of indexes are. If you take a reference book, you have the two types...
2013-11-20
1,693 reads
What? You want to see all of your data? Well do I have the script for you! New, Improved, Extra...
2013-11-20
465 reads
Tonight I had the pleasure of presenting remotely to the Triangle SQL Server Users Group. I presented my session entitled “Squeezing...
2013-11-20
629 reads
Microsoft has released SQL Server 2008 Service Pack 3 Cumulative Update 14, which is build 10.00.5848. This Cumulative Update has...
2013-11-19
1,194 reads
SQLBits in Nottingham was where it all began. A short conversation on whether there were any plans for a SQL...
2013-11-19
841 reads
I had a great comment (Ryan McCauley’s) on yesterday’s post that led to a great conversation on Twitter. The comment mentioned...
2013-11-27 (first published: 2013-11-19)
2,067 reads
I recorded my first video presentation and demo using the screen recording and video editing software called Camtasia Studio for Windows.
It’s...
2013-11-19
588 reads
It’s kind of fun to see Azure development artifacts on display. I’ve posted about them before, a couple of times....
2013-11-19
878 reads
A big thanks to everyone who participated in this month’s T-SQL Tuesday (link) blog party. This month’s topic was to give your thoughts on Cloud. Lots of interesting reads...
2013-11-19
13 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