Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SELECT
- name_store,
- COUNT(DISTINCT name) as name_uniq_cnt
- FROM
- products_data_all
- GROUP BY
- name_store
- HAVING
- COUNT(DISTINCT name) > 30
- ORDER BY
- name_uniq_cnt
- LIMIT
- 3
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement