🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #987

SQL: How to find duplicated values

#987
From: Vladimir Stefanovic
Date: Tue, 22 Feb 2005 17:56
25 lines
1596 bytes
I have a table (MS ACCESS) with 2 fields:

   1 field: MyText (TEXT)
   2 field: MyBool (BOOL)

...which both should make a primary key, but first I
have somehow to get rid of duplicates:

I need an SQL which can find duplicates for me by
any of those tools: SQL Explorer, MS Access Query or
BCB6&ADOQuery.

Also why this do not work with any of the tools mentioned:

// This is only for a single field, not for both
select MyText, count(MyText) as Counter
from SomeTable
group by MyText
where Counter>1



-- 
Best regards,
Vladimir Stefanovic 
Technical Details
Message-ID: <421b7242$2@newsgroups.borland.com>
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!feeder2.on.meganewsservers.com!meganewsservers.com!textfeed1.on.meganewsservers.com!38.119.100.83.MISMATCH!news-out.nntp.be!propagator2-sterling.newsfeeds.com!news-in.nuthinbutnews.com!news-in.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Thread: 10698b,acc64c952c569a2b,start
X-Google-Attributes: gid10698b,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: "Vladimir Stefanovic" <antivari@po.sbb.co.yu>
Newsgroups: borland.public.cppbuilder.database.ado
Subject: SQL: How to find duplicated values
Date: Tue, 22 Feb 2005 18:56:23 +0100
Lines: 27
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
X-RFC2646: Format=Flowed; Original
NNTP-Posting-Host: 82.117.212.65
Message-ID: <421b7242$2@newsgroups.borland.com>
X-Trace: newsgroups.borland.com 1109094978 82.117.212.65 (22 Feb 2005 09:56:18 -0800)
Path: arc1-ca.pugleaf.net!g2news1.google.com!news4.google.com!news.glorb.com!feeder2.on.meganewsservers.com!meganewsservers.com!textfeed1.on.meganewsservers.com!38.119.100.83.MISMATCH!news-out.nntp.be!propagator2-sterling.newsfeeds.com!news-in.nuthinbutnews.com!news-in.newsfeeds.com!in.nntp.be!caladan.landsraad.net!newsgroups.borland.com!not-for-mail