DELETE
FROM test
WHERE 1=1
AND foo = ?
ORDER BY
  bar DESC
LIMIT 1

