Common Mistakes in SQL Server – Part 2
The Identity property creates an incremental value for the specified column automatically, which is why it is widely used by developers when they designed the table and a primary...
2023-09-25
91 reads
The Identity property creates an incremental value for the specified column automatically, which is why it is widely used by developers when they designed the table and a primary...
2023-09-25
91 reads
The Identity property creates an incremental value for the specified column automatically, which is why it is widely used by developers when they designed the table and a primary...
2023-09-25
29 reads
Enable PowerShell Remoting
I use PowerShell quite a lot to manage servers, especially SQL Servers. So I need to be able to run PowerShell...
2023-09-25 (first published: 2023-09-24)
253 reads
The Future Data Driven 2023 virtual conference is coming on Wednesday, September 27. Register today and save a note in your calendar. The event has a great schedule (scroll...
2023-09-25
21 reads
A few years ago SQL Prompt added a command palette to let you search the commands available. This is similar to the same concept in Visual Studio Code, ADS,...
2023-09-25
96 reads
One of the things that I feel is important to building better software is testing your code. It should be easy and simple to test code and determine if...
2023-09-25 (first published: 2023-08-28)
395 reads
My slides are here: VCS Primer Denver 2023 This was an overview of what version control is, and the basics of Git. Not too many questions, but if you...
2023-09-25
27 reads
Yet another kind of orphan users in SQL Server
Or YAOU for short. (This silly acronym, I just made it up so don’t try...
2023-09-25 (first published: 2023-09-02)
1,339 reads
A Study in SQL Server Ad hoc Query Plans
We, (or maybe it’s just my dismissive attitude towards it), often think of ad hoc...
2023-09-23 (first published: 2023-09-22)
407 reads
Get Configuration Change History From the SQL Server Error Logs
There are several options if and when you need to see if any configuration change was...
2023-09-23
170 reads
By Steve Jones
I use ConEmu for my terminal interface. I’m still on Windows 10 at home,...
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...
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