cbrown6305
New Member
- Joined
- Nov 12, 2018
- Messages
- 13
- Office Version
- 2016
- Platform
- Windows
Hello,
I am working with a large data set that I have housed in the excel data model via a power query and am using power pivot to bring data into my workbook. The data has three columns of interest for me: service date, collection date, and payment. Formerly, when the data was housed in a standard table, I would just run a sumifs function on a monthly date column in order to retrieve all payments that were collected after month end for service dates prior to that month. The prior formula looked like this...
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Month End[/TD]
[TD]Monthly Result[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]12/31/17[/TD]
[TD]=sumifs(Table1[payment],Table1[collection date],">"&A2,Table1[service date],"<="&A2)[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]01/31/18[/TD]
[TD]=sumifs(Table1[payment],Table1[collection date],">"&A3,Table1[service date],"<="&A3)[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]02/29/18[/TD]
[TD]=sumifs(Table1[payment],Table1[collection date],">"&A4,Table1[service date],"<="&A4)[/TD]
[/TR]
</tbody>[/TABLE]
Since I am now housing the data in the power pivot/data model, I can't just run a formula on the data set. I can only query the data set using a pivot table. I have considered creating a pivot table for the entire data set and running the above formula, but that would defeat the purpose of housing the data in the data model via power query. I'd much rather run a pivot table that functions just as the above calculation does. I think that the answer lies somewhere with DAX measures, but I can't quite figure it out.
Thanks for your help!
I am working with a large data set that I have housed in the excel data model via a power query and am using power pivot to bring data into my workbook. The data has three columns of interest for me: service date, collection date, and payment. Formerly, when the data was housed in a standard table, I would just run a sumifs function on a monthly date column in order to retrieve all payments that were collected after month end for service dates prior to that month. The prior formula looked like this...
[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A[/TD]
[TD]B[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]Month End[/TD]
[TD]Monthly Result[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]12/31/17[/TD]
[TD]=sumifs(Table1[payment],Table1[collection date],">"&A2,Table1[service date],"<="&A2)[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]01/31/18[/TD]
[TD]=sumifs(Table1[payment],Table1[collection date],">"&A3,Table1[service date],"<="&A3)[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]02/29/18[/TD]
[TD]=sumifs(Table1[payment],Table1[collection date],">"&A4,Table1[service date],"<="&A4)[/TD]
[/TR]
</tbody>[/TABLE]
Since I am now housing the data in the power pivot/data model, I can't just run a formula on the data set. I can only query the data set using a pivot table. I have considered creating a pivot table for the entire data set and running the above formula, but that would defeat the purpose of housing the data in the data model via power query. I'd much rather run a pivot table that functions just as the above calculation does. I think that the answer lies somewhere with DAX measures, but I can't quite figure it out.
Thanks for your help!