Опитайте тази заявка
SELECT *
FROM products
WHERE items = 'apple'
AND itemtype = '1'
AND id >
(
SELECT MIN(id) AS id
FROM products
WHERE items = 'apple'
AND itemtype = '1'
)
AND id <
(
SELECT MIN(id)
FROM products
WHERE items = 'apple'
AND itemtype = '0'
AND id >
(
SELECT MIN(id) AS id
FROM products
WHERE items = 'apple'
AND itemtype = '1'
)
);