Maintenance and Management

Technical Article

Eliminate Duplicates

  • Script

This will find and delete all duplicate rows. You can refine the granularity of uniqueness by including more columns than just the Primary Key. If you are picky about which rows you want to delete, don't use this. Instead use the 'Find Duplicates' script I just submitted and then delete manually.

You rated this post out of 5. Change rating

2002-05-24

1,086 reads

Technical Article

Find Duplicates

  • Script

Find duplicates in any table, and report the number of duplicates. Enter in the table name, and the field or fieldsfor which there should only be one row for each of that field, but you suspect are more. For example, if an employee table has more than one record for an employeethis will find any […]

5 (1)

You rated this post out of 5. Change rating

2002-05-24

576 reads

Technical Article

Check in New DDL to SourceSafe

  • Script

Rather than invent (or learn) a whole new set of tools to preserve and version all DDL underneath our databases, we decided to use SourceSafe (something we're already using for all other source code). -- We've developed this VBscript to run nightly; it recreates object-level DDL in a given database and compares each object's script […]

You rated this post out of 5. Change rating

2002-05-09

144 reads

Blogs

Dynamically Unpivot columns in SQL

By

Picture this, your data ingestion team has created a table that has the sales...

Friday Basics: RPO and RTO

By

I did a post last month titled RTO and RPO are myths unless you've...

A New Word: ioia

By

ioia – n.the wish that you could see statistics overlaid on every person you...

Read the latest Blogs

Forums

SQL Server Encrypt data into a file, send it and then decrypt

By GBeezy

First off, my apologies for what could potentially be a bad title! I am...

Table partitioning best practice

By JasonO

I've inherited a couple of rather large databases from my ex-colleague when I join...

Identifying Customer Buying Pattern in Power BI - Part 2

By Farooq Aziz

Comments posted to this topic are about the item Identifying Customer Buying Pattern in...

Visit the forum

Question of the Day

Finding Marks

I have marked a few transactions in my code. How can I find out which marks were stored in a transaction log?

See possible answers