|
Assumed you want to update the first record of a list of records
with a duplicate pallet number and duplicate date. (you may even add
a WHERE condition to only filter a specific date:
Here is another solution:
Update yourtable x
set MyDate = '2013-07-18'
where rrn(x) in (Select RRNa
from (Select Palet, myDate, min(rrn(a)) RRNA
from yourtable a
/* optionally */ where myDate = '2013-07-19'
group by Palet, Mydate
having count(*) > 1
) b
)
;
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact copyright@midrange.com.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.