MySQL
- 4 ответа
- 0 вопросов
3
Вклад в тег
SELECT `test`.*
FROM `test`
LEFT JOIN
(SELECT `date`, `operator_id`
FROM `test`
GROUP BY `date`, `operator_id`
HAVING COUNT(*)>1) as `tbl`
ON
`test`.`date`=`tbl`.`date` AND
`test`.`operator_id` = `tbl`.`operator_id`
WHERE `tbl`.`date` IS NOT NULL