Mysql limit 1. id AS product_id, p. You can use SET max_seeks_for_key= val...