Count Distinct in a Group By aggregate function in Access 2007 SQL

后端 未结 3 2025
无人及你
无人及你 2021-01-06 09:56

Hello I have browsed the forum for a while and am asking my first question here. I\'m in a bit of a bind and was wondering if I could get some help out. I am using Access 20

3条回答
  •  耶瑟儿~
    2021-01-06 10:29

    This works in Access 2007 and 2010:

    select format(sum(bpa_ext_price) /
                  (select count(*) from (select distinct ord_num from sales)),
                 "standard") AS Avg_Ord_Amt
    from   sales
    

提交回复
热议问题