其中条件进入SQL with group by

时间:2016-02-11 11:42:16

标签: sql ms-access

如何添加以下条件:

Sum([Report 1].[CA Service Bookings Net]) 

关于LEVEL [报告1]。[最终客户全球终极公司目标ID]是否超过250万?

"目标ID"是0级,

" Geo ID"是1级(1下)

SELECT [Report 1].[Fiscal Year], 
       [Report 1].[BE Geo ID],
       [Report 1].[End Customer Global Ultimate Company Target ID],
       Sum([Report 1].[CA Service Bookings Net]) AS BOOKINGS

FROM [Report 1]

WHERE [Report 1].[End Customer Global Ultimate Company Target ID] = 146853
      AND [Report 1].[Sales Level 2] = "EMEAR-NORTH"

GROUP BY [Report 1].[Fiscal Year], 
         [Report 1].[End Customer Global Ultimate Company Target ID],
         [Report 1].[Finance BU/Service Category],
         [Report 1].[BE Geo ID]

0 个答案:

没有答案