The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi everyone
I have fact table with some sales. The table records the sales per day. I also have a dimesion kalender table and a relationship between the two tables. The calendertable has dates into the future. I would like a dax formula the can show me the sales today 6 months ago. Can anyone help with that?
Sincerely
Christian
Hi,
I am not sure how your datamodel looks like but I tried to create a sample pbix file like below.
Please check the below picture and the attached pbix file.
I hope the below can provide some ideas on how to create a solution for your datamodel.
Sales total: =
SUM( Sales[Sales] )
Sales 6 months ago: =
CALCULATE ( SUM ( Sales[Sales] ), DATEADD ( 'Calendar'[Date], -6, MONTH ) )
User | Count |
---|---|
17 | |
8 | |
7 | |
6 | |
6 |
User | Count |
---|---|
26 | |
13 | |
12 | |
9 | |
8 |