Re: Help with duplicate records in SQL
Date: Tue, 9 Jun 1992 20:29:23 GMT
Message-ID: <1992Jun9.202923.27772_at_cas.org>
In article <1992Jun9.174807.23227_at_cas.org> kxh26_at_cas.org (Kenneth D. Huffman) writes:
>>BZZZZZT!
>But what if there are three (or more)-way duplicates?
>(This select is also simpler.)
>
> DELETE FROM bigtable
> WHERE rowid > (
> SELECT min(rowid)
> FROM bigtable
> GROUP BY part, name, vendor, status);
>--
BZZZZZT, you can't do anything right. I should know.
Try replacing the '>' with 'NOT IN' and you should be in business.
>"Computers are useless. They can only give you answers." - Pablo Picasso
>Kenneth D Huffman Work: Chemical Abstracts Service Play: 2740 Wynnerock Ct
><kxh26_at_cas.org> Box 3012, Columbus OH 43210 Hilliard OH 43026
><kxh26_at_cas.bitnet> 614-447-3838 ext. 2290 614-771-6334
-- "Computers are useless. They can only give you answers." - Pablo Picasso Kenneth D Huffman Work: Chemical Abstracts Service Play: 2740 Wynnerock Ct <kxh26_at_cas.org> Box 3012, Columbus OH 43210 Hilliard OH 43026 <kxh26_at_cas.bitnet> 614-447-3838 ext. 2290 614-771-6334Received on Tue Jun 09 1992 - 22:29:23 CEST