RYO Maintenance Plan – Update Statistics
Another key component of any good maintenance plan is updating statistics. Statistics are what help the SQL Server optimizer choose...
2012-02-27 (first published: 2012-02-21)
2,562 reads
Another key component of any good maintenance plan is updating statistics. Statistics are what help the SQL Server optimizer choose...
2012-02-27 (first published: 2012-02-21)
2,562 reads
I’m hoping to do a presentation at SQLRally in Dallas on May 10-11, but I need your help!
There is a...
2012-02-21
735 reads
I was chatting with a friend recently who had been in turn chatting with a colleague about first impressions. The...
2012-02-21
976 reads
Deleting duplicate rows out of a table can be tricky. A brute force way to do this is with a...
2012-02-28 (first published: 2012-02-21)
4,246 reads
Here's a script from my toolbox I use to find dependencies between SQL objects. The where clause has a number...
2012-02-21
1,047 reads
I received great news last week that one of my sessions, Windows Operating System Internals for DB Pros, was accepted,...
2012-02-21
866 reads
for sql server 2000 (I know its old) desktop edition does not includes any GUI. so installation of desktop edition...
2012-02-21
2,483 reads
No matter how simple it is, new things come with some confusion; at least until you get used to it....
2012-02-21
4,581 reads
Today’s script is one I have used to test one possible upgrade method from SQL Server 2008 to SQL Server...
2012-02-21
979 reads
I’ll show you mine if you show me yours. Over the past nine years or so, I have showcased many...
2012-02-21
918 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