PowerShell script repository - SQL Server
A simple get-help output
PowerShell is a .Net based command line tool designed for automation.
It is recommended to script repetitive task...
2018-03-21
314 reads
A simple get-help output
PowerShell is a .Net based command line tool designed for automation.
It is recommended to script repetitive task...
2018-03-21
314 reads
If you encounter the following error trying to access reporting services:
User XXXX does not have required permissions. Verify that sufficient...
2018-03-02
271 reads
One of the most basic things to improve performance in our queries is using indexes, but this doesn't mean that...
2018-02-14
564 reads
Stress everywhere, user wants everything "Para ayer"Photo by Bernard Goldbach
If you are like me, and have SQL Server instances with...
2018-02-01
599 reads
A bug was recently discovered on almost every processor made on the last 10 years, and it seems that almost...
2018-01-05
65 reads
From SQL Guatemala, we wish you a happy new year 2018.
We hope this new year brings you joy and zero:...
2017-12-30
330 reads
A very interesting feature was recently added to SQL Server Management Studio 17.4 (SSMS): The new SQL Vulnerability Assessment.
What is...
2017-12-12
157 reads
To check the available advanced options configured at instance level in SQL Server, you need to use the sp_configure system...
2017-11-24
45,481 reads
I have recently obtained the certification Microsoft Certified Solutions Associate: SQL Server 2012/2014.
I began with this path almost 2 years...
2017-11-20
97 reads
I am sharing today a SQL Script to quickly check on an instance which databases are in mirrored and their...
2017-11-10
6,696 reads
By Steve Jones
Thanks to everyone that attended my sessions at VS Live San Diego yesterday. It...
By Steve Jones
I was creating a question on sp_readerrorlog and realized that this procedure is different...
By SQLPals
Why sys.fn_dblog Is Undocumented And Why It's Still There Why sys.fn_dblog...
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