View Single Post
Old 02-22-2013, 09:07 PM   PM User | #12
Old Pedant
Supreme Master coder!

 
Old Pedant's Avatar
 
Join Date: Feb 2009
Posts: 23,162
Thanks: 59
Thanked 3,992 Times in 3,961 Posts
Old Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to allOld Pedant is a name known to all
Perfect then.

And trivial:
Code:
DELETE t1 
FROM tablename AS t1, tablename AS t2
WHERE t1.lnktxt = t2.lnktxt
  AND t1.cattxt = t2.cattxt
  AND t1.datetxt < t2.datetxt
ALSO: If you happen to have 3 (or more!) records with the same lnktxt and cattxt values, that will delete *all* of them except the one with the latest datetxt field.
__________________
An optimist sees the glass as half full.
A pessimist sees the glass as half empty.
A realist drinks it no matter how much there is.
Old Pedant is offline   Reply With Quote
Users who have thanked Old Pedant for this post:
mharrison (02-22-2013)