Access Sumifs

mahmed1

Well-known Member
Joined
Mar 28, 2009
Messages
2,302
Office Version
  1. 365
  2. 2016
Platform
  1. Windows
Hi

how can I achieve this same result in Access...

essentially i want to add up the AHT column and divide the totals column only if the date is > #01/01/2020# AND < #01/02/2020# AND TYPE = ‘YELLOW’ and put this result in Weighted column

i tried this with no luck

Select Date_, Type, Total, Sum[AHT Colum]/[Total] as Weighted Column
WHERE Date_ > #01/01/2020# AND Date_< #01/02/2020# AND Type = ‘YELLOW’
Group by Date_, Type, Total
 

Excel Facts

Pivot Table Drill Down
Double-click any number in a pivot table to create a new report showing all detail rows that make up that number
What is the name of your table?
 
Upvote 0
This?
SQL:
SELECT 
   Date_, 
   Type, 
   Total, 
   Sum([AHT Colum])/Sum([Total]) AS [Weighted Column]
FROM
   tbl_RawData_Rolling
WHERE 
   Date_ > #01/01/2020# AND Date_ < #01/02/2020# AND Type = ‘YELLOW’
GROUP BY 
   Date_, 
   Type, 
   Total
 
Upvote 0
If you still have trouble post a few rows of sample data and expected result with that data.
 
Upvote 0

Forum statistics

Threads
1,213,532
Messages
6,114,177
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top