Interesting. The description wasn't very clear. I interpreted it to mean a simple count of Product/Depot items
the problem is that the terms aren't consistent. The title attachments shows "No. of Distributor Billed?" but there is not "Distributor" column. If, we interpret "Distributor" as the "BP Name" column. Then, the question becomes "How many unique 'BP Names' for each Product/Depot combination". In THAT case, what I would do is: Add a "Helper" column (D) and concatenate the other columns: =A2&"-"&C2&"-"&B2 Copy it down, Copy this column and paste it as Values Remove Duplicates Then, in the Summary table, use: =COUNTIF($D:$D,$E7&"-"&F$6&"*") that should do the trick. (of course, all of this could be automated with a macro) Paul ________________________________ From: Ayush <jainayus...@gmail.com> To: excel-macros@googlegroups.com Sent: Thu, January 6, 2011 7:43:46 AM Subject: Re: $$Excel-Macros$$ How to count distinct values on the base of multiple criteria Right Paul, but your formula is counting duplicate values also.This user need to count only distinct values. correct ? Best Regards, Ayush Jain -- ---------------------------------------------------------------------------------- Some important links for excel users: 1. Follow us on TWITTER for tips tricks and links : http://twitter.com/exceldailytip 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 3. Excel tutorials at http://www.excel-macros.blogspot.com 4. Learn VBA Macros at http://www.quickvba.blogspot.com 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com <><><><><><><><><><><><><><><><><><><><><><> Like our page on facebook , Just follow below link http://www.facebook.com/pages/discussexcelcom/160307843985936?v=wall&ref=ts -- ---------------------------------------------------------------------------------- Some important links for excel users: 1. Follow us on TWITTER for tips tricks and links : http://twitter.com/exceldailytip 2. Join our LinkedIN group @ http://www.linkedin.com/groups?gid=1871310 3. Excel tutorials at http://www.excel-macros.blogspot.com 4. Learn VBA Macros at http://www.quickvba.blogspot.com 5. Excel Tips and Tricks at http://exceldailytip.blogspot.com To post to this group, send email to excel-macros@googlegroups.com <><><><><><><><><><><><><><><><><><><><><><> Like our page on facebook , Just follow below link http://www.facebook.com/pages/discussexcelcom/160307843985936?v=wall&ref=ts