Dates and Times in SQL Server: the science of time
Now that we have covered the various date and time data types (see the post from last time) in SQL...
2018-04-11
865 reads
Now that we have covered the various date and time data types (see the post from last time) in SQL...
2018-04-11
865 reads
Database Code Smells
I was recently reviewing a newly created T-SQL stored procedure. This procedure was verifying temporary table existence with...
2018-04-11
2,404 reads
I often hear people say moving to the cloud does not save money, but frequently they don’t take into account...
2018-04-11
170 reads
I often hear people say moving to the cloud does not save money, but frequently they don’t take into account...
2018-04-11
1,017 reads
With all the noise about the upcoming enforcement of GDPR, I know that people are starting to focus more on...
2018-04-11
450 reads
Join me in two weeks for a really fun free webcast. Update: watch the recording of the webcast here! DBA vs Memory Settings Tues, April 24, 2018 – 8:30AM...
2018-04-11
12 reads
A recovery model is a database configuration option that determines the type of backup that one could perform and provides...
2018-04-11
781 reads
Tonight, April 11th starting at 6PM, the Baton Rouge SQL Server User Group will hold its monthly meeting. The Baton Rouge .Net User Group does the same at the...
2018-04-11
14 reads
Tonight, April 11th starting at 6PM, the Baton Rouge SQL Server User Group will hold its monthly meeting. The Baton...
2018-04-11
317 reads
SQL Server 2017 In-Database Machine learning has brought the analytics closer to the data. It is now convenient to do...
2018-04-11
963 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