I have a store
table, and the sql is
SELECT * FROM `store` GROUP BY `store_name`, `country`, `branch`
The output is
store_name | country | branch |
---|---|---|
store_a | US | New_York |
store_a | US | Texas |
store_b | Japan | Tokyo |
store_c | German | Hamburg |
store_c | German | Berlin |
store_c | German | Hesse |
store_d | French | Paris |
Now I want to show stores have more than 1 branches
This is what I expect:
store_name | country | branch |
---|---|---|
store_a | US | New_York |
store_a | US | Texas |
store_c | German | Hamburg |
store_c | German | Berlin |
store_c | German | Hesse |
How to achieve this?