Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a table with the unique key of Customer Number and a field that has the Master Customer number. The master customer represents the customer number that they are associated with. Say for example a person owns 10 stores. Then the table will have 10 unique Customer Numbers (ie CustromerNumber1, CustomerNumber2, CustomerNumber3 . . . CustomerNumber10) and for each of the 10 customers they will have the same Master Customer number (ie CustomerNumber1). If an owner has only one store then the Customer Number and the Master Customer number will be the same.
I need to load this table with the Master Customer Number and the total count of the master customers. So in the above example I want to:
MasterCustomerNumber - Total Count
CustomerNumber1 - 10
CustomerNumber 11 would be the next customer to list and may have a 1 for the count ir maybe a 5 if the owner owns 5 stores.
How do I do this?
Thanks,
Stephen
As I see it you could add a field dummy with ' 1 ' as value and then do a group by Master Customer and sum the dummy field.
Hope it helps!
Thanks Carlos,
That put me on the right path. Problem solved!
Stephen