我不是MS Access方面的专家,上次我为它编写任何内容都花了很长时间,但这也许行得通:
SELECT cd.DiagCode, Count(cd.CustomerID)
FROM (select distinct DiagCode, CustomerID from CustomerTable) as cd
Group By cd.DiagCode;
在Access 2007 SQL中按聚合功能对分组中的差异进行计数
我不是MS Access方面的专家,上次我为它编写任何内容都花了很长时间,但这也许行得通:
SELECT cd.DiagCode, Count(cd.CustomerID)
FROM (select distinct DiagCode, CustomerID from CustomerTable) as cd
Group By cd.DiagCode;