I have a table with data that is broken down as follows:
countryCode, cityCode, storeCode, storeType, gridCodeX
I need to get a result, distinct, from this table so it totals up how many distinct gridCodeX's there are in a store within a city within a country
I have tried the following in around 100 itterations but to no avail!
Any help would be much appreciated.
select distinct countrycode,citycode,storecode,count(gridcodex) from block
group by countrycode,citycode,storecode, gridCodeX