sql update where id in subquery