I have this query
SELECT *, min(id)
FROM mytable
WHERE col2='specval'
GROUP BY col3
that selects rows I need.
I would like to set
UPDATE mytable
set col4 = col3+1000
for the rows selected above respectively.
So, how to update that rows by setting col4 in that table as col4=col3+1000 only for each selected row respectively?
Thank you.