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,934 reads

Blogs

Narrow Task Decomposition in AI Pipeline Agents

By

A nightly load into sales_fact fails. Ask an orchestrating agent to break down the...

Car Update: August 2026

By

It’s been some time since I provided a car update, so I decided to...

Microsoft Fabric OneLake Shortcuts: When to Use Them and When Not To

By

An architecture scenario Imagine separate Sales, Finance, Shared Data, and Executive Analytics workspaces. Sales...

Read the latest Blogs

Forums

Backing Up a DMK

By Steve Jones - SSC Editor

Comments posted to this topic are about the item Backing Up a DMK

The Quiet Part

By Steve Jones - SSC Editor

Comments posted to this topic are about the item The Quiet Part

BIT_COUNT in SQL Server

By john.martin

Comments posted to this topic are about the item BIT_COUNT in SQL Server

Visit the forum

Question of the Day

Backing Up a DMK

In SQL Server 2025, I have a database with a Database Masker Key (DMK). I want to back up this key and keep a copy offline. When do I have to open this key before running the backup?

See possible answers