Can I Change a Primary Key Value? #SQLNewBlogger
I heard someone say recently that you can’t change a primary key value in a row. That’s not the case, so I decided to show a quick proof of...
2025-05-02 (first published: 2025-04-23)
525 reads
I heard someone say recently that you can’t change a primary key value in a row. That’s not the case, so I decided to show a quick proof of...
2025-05-02 (first published: 2025-04-23)
525 reads
I was chatting with a customer recently and they wanted to know which host was sending in queries that were causing problems in real time. This post looks at...
2025-05-05 (first published: 2025-04-21)
530 reads
immerensis – n. the maddening inability to understand the reasons why someone loves you – almost as if you’re selling them a used car that you know has a...
2025-04-18
70 reads
When in doubt, overtip – from Excellent Advice for Living This is close to my heart, since I spent a lot of time in college and after working as...
2025-04-11
28 reads
This month we have an interesting invite. Erik Darling is the host, and since he does a lot of video blogs, he’s asking for a video submission for T-SQL...
2025-04-08
18 reads
There is a SET command in SQL Server that changes how much data is returned from some fields. This short post shows what I learned about the SET TEXTSIZE...
2025-04-25 (first published: 2025-04-07)
512 reads
As a part of the Book of Redgate, we have a series of (red, of course) pages with the title “What we believe”. These are our values, as set...
2025-04-18 (first published: 2025-04-04)
422 reads
A customer asked if they needed to restore a database from backup to compare the schema in a database. They don’t and this post shows that. This is part...
2025-04-21 (first published: 2025-03-31)
285 reads
zverism – n. the wish that people could suspend their civility and indulge in the physical side of each other first, sniffing each other’s hair like dogs, staring unabashedly...
2025-03-28
86 reads
We recently published an article on CHOOSE at SQL Server Central. I thought it was a good intro, but as someone noted in the comments, how do you use...
2025-04-09 (first published: 2025-03-26)
286 reads
When I put together the invitation for T-SQL Tuesday #202, I wasn't sure what...
By Steve Jones
My life has some crazy travel stretches for sure. Between speaking, office visits, customer...
In Part 1, we saw how ‘Vamana’ represents vectors as nodes, connects them with...
Comments posted to this topic are about the item Implementing Type 4 Slowly Changing...
Comments posted to this topic are about the item The Disabled Index
Comments posted to this topic are about the item Server-Level Table sizes
I run this code on SQL Server 2022.
CREATE TABLE Drink
(
drinkid INT NOT NULL
CONSTRAINT DrinkPK PRIMARY KEY CLUSTERED,
drinkname VARCHAR(20),
rating NUMERIC(2, 1)
)
GO
INSERT INTO Drink
(
drinkid,
drinkname,
rating
)
VALUES
(1, 'Margarita', 4.5),
(2, 'Mojito', 4.3),
(3, 'Old Fashioned', 4.7),
(4, 'Martini', 4.4),
(5, 'Cosmopolitan', 4.2)
GO
ALTER INDEX drinkpk ON dbo.drink DISABLE
GO
SELECT * FROM dbo.Drink
GO
What is the result? See possible answers