Scripts

Technical Article

Primary Keys which are not Clustered Indexes in a database

Recently I was asked to find all the Primary keys that are not clustered Indexes in the database. I constructed the below script which will help us to locate the primary keys in the database which are not clustered index.

★ ★ ★ ★ ★ ★ ★ ★ ★ ★

(5)

You rated this post out of 5. Change rating

2013-09-18 (first published: )

1,968 reads

Blogs

Wait… Could This Be the End of Index Maintenance?

By

While attending SQLCon and FabCon Europe in Barcelona, there were a lot of announcements...

Copilot on the Power BI Report Canvas vs. Modern Report Builder

By

(This is the second post in a three-part series on how AI is changing...

The #MS_DatabaseConnector## Role: #SQLNewBlogger

By

I had seen these roles in various instances, but never dug into the new...

Read the latest Blogs

Forums

Pay for Performance

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Pay for Performance, which is...

Layanan Resmi BCA KCU CIANJUR Telp:0817°825°533

By layanan_Bca88

Telp/Wa 62817825533 Jl. HOS Cokro Aminoto No.56-58, Muka, Kec. Cianjur, Kabupaten Cianjur, Jawa Barat...

Layanan Resmi BCA KCU DEPOK Telp:0821°7555°651

By m4rt1n4

Telp/Wa 628217555651 Jl. Margonda Raya No.182, Kemiri Muka, Kecamatan Beji, Kota Depok, Jawa Barat...

Visit the forum

Question of the Day

The ##MS_DatabaseConnector## User

On SQL Server 2025, I run this code as a sysadmin:

CREATE LOGIN Demo WITH PASSWORD = 'Demo1234567'
GO
ALTER SERVER ROLE ##MS_DatabaseConnector## ADD MEMBER Demo
GO
I then login as Demo and run this:
USE sandbox
go
SELECT CURRENT_USER
What is returned?

See possible answers