Wednesday, April 02, 2014

Check for duplicates SQL

SELECT
    contentid, contenttypefieldid, COUNT(*)
FROM
    contentvalue
GROUP BY
    contentid, contenttypefieldid
HAVING
    COUNT(*) > 1

Wednesday, February 19, 2014

An old one, but worth remembering...

Resetting the identity value of any SQL table is as easy as follows:

USE AdventureWorks2012;
GO
DBCC CHECKIDENT ('Person.AddressType', RESEED, 10);
GO
 
http://technet.microsoft.com/en-us/library/ms176057.aspx
 
 

Fixes to common .NET problems, as well as information on .NET features and solutions to common problems that are not language-specific.

Fixes to common .NET problems, as well as information on .NET features and solutions to common problems that are not language-specific.

Z