select distinct loc, count(loc) over (partition by loc) subtotal, count(loc) over () total, (count(loc) over (partition by loc)) / (count(loc) over ()) * 100 dshare from cust order by loc;