March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hello people,
I am new to Power BI. I need a new column that subtracts two rows of a table.
I have this table, and I need show the anual growth of each database, so I want to generate a column that subtracts the USED_GB of the current year less those of the previous year of each database.
The idea is to generate this new column in DAX. How can I do that?
Thanks.
Hi Ajendra,
This is the desire output, but I would like not view the rows with PREVIOUS_YEAR with empty values:
Thanks.
hi @GRANDEF
try to add a calculated column like:
column =
VAR _pre =
MAXX(
FILTER(
data,
data[DATABASE]=EARLIER(data[DATABASE])
&&YEAR(data[DATE])=YEAR(EARLIER(data[DATE]))-1
),
data[USED_GB]
)
RETURN
[USED_GB] - _pre
it worked like:
Hi FreemanZ, thanks for your help.
I tried this, but my PowerBi showed this error (My table name is
Regards.
Hello,
Please provide some dummy data alongwith the desire output. Thanks!!
Ajendra!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
23 | |
16 | |
12 | |
9 | |
7 |
User | Count |
---|---|
38 | |
32 | |
28 | |
12 | |
11 |