TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
David Smith
NA
2k
0
SQL Distinct
Jul 30 2012 4:10 AM
Can someone tell me why the dataset below keeps returning duplicate ContactIds and I am asking for Distinct in the query. I am totally confused.
SELECT Distinct tblContact.ContactID, (tblContact.FirstName) AS MinOfFirstName, tblContact.LastName, tblContact.PhoneHome, tblContact.Location, tblContact.AddressStreet, tblContact.AddressStreetCity, tblContact.AddressStreetZIP, tblContact.AddressDirections, tblContact.AddressPost, tblContact.AddressPostCity, tblContact.AddressPostZIP, tblContact.EmailAddress, tblContact.Gender, tblContact.Spouse, tblContact.Title, tblContactType.ContactStatus, tblContact.Birthday, tblContact.GAP
FROM (tblContact LEFT JOIN tblContactType ON tblContact.ContactID = tblContactType.ContactID) LEFT JOIN tblContactService ON tblContact.ContactID = tblContactService.ContactID
Where tblContactService.ServiceType = 2
Reply
Answers (
7
)
Delete Duplicate Rows From Table In Sql Server with No Identity Column in table
CHECK constraint in SQL server