The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event: Join us in Stockholm, September 24-27, 2024.
Save €200 with code MSCUST on top of early bird pricing!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hello,
I made a db where our printerdata is sent to on a daily basis. 6 properties/OID's are scanned:
I want to add an extra column wich calculates the difference from the last day but for the same printer and OID.
So far i got something like this:
Solved! Go to Solution.
Hi @driesvdb ,
To create a measure as below.
difference = VAR dat = [Date] - 1 VAR pre = CALCULATE ( SUM ( 'Table'[Count] ), FILTER ( 'Table', 'Table'[PrinterID] = EARLIER ( 'Table'[PrinterID] ) && 'Table'[TypecounterID] = EARLIER ( 'Table'[TypecounterID] ) && [Date] = dat ) ) RETURN IF ( pre = BLANK (), BLANK (), 'Table'[Count] - pre )
Hi @driesvdb ,
To create a measure as below.
difference = VAR dat = [Date] - 1 VAR pre = CALCULATE ( SUM ( 'Table'[Count] ), FILTER ( 'Table', 'Table'[PrinterID] = EARLIER ( 'Table'[PrinterID] ) && 'Table'[TypecounterID] = EARLIER ( 'Table'[TypecounterID] ) && [Date] = dat ) ) RETURN IF ( pre = BLANK (), BLANK (), 'Table'[Count] - pre )
When I enter the lines the collumn is still empty, no calculation seems te be done.
In the link below is the .pbix file ( I don't have enough rights to upload it directly )
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the June 2024 Power BI update to learn about new features.
User | Count |
---|---|
141 | |
109 | |
108 | |
76 | |
63 |
User | Count |
---|---|
273 | |
129 | |
123 | |
101 | |
91 |