Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi,
I'm trying to add a fixed value to my GP Per Lift measure. The measure below works, but if i add a fixed value of 3.5 it crashes my report.
This measure has a fixed value:
The below measure crashes my report.
Please find the link to my report below any help is much appreciated.
https://www.dropbox.com/s/n2fvokgrte5wvxg/Power%20BI%20Sample.pbix?dl=0
Solved! Go to Solution.
Returning constants from measures is generally a very bad idea. If you have 1000 customers 1000 products and 2 years worth of data (so 730 days) and you drag the product, customer and date onto a table with the operational cost measure the table will attemtp to return a row for every combination (so 1000 x 1000 * 730) which would be 730 million rows.
So I would suggest doing something like the following where you check if the measure is not blank before adding the constant value to it.
GP per Lift (excluding rent & doc) = VAR _operationCost = 3 VAR _part1 = [Lift Rate] - [Disposal Cost per Lift] RETURN IF( NOT( ISBLANK( _part1 ) ), _part1 + _operationCost )
Returning constants from measures is generally a very bad idea. If you have 1000 customers 1000 products and 2 years worth of data (so 730 days) and you drag the product, customer and date onto a table with the operational cost measure the table will attemtp to return a row for every combination (so 1000 x 1000 * 730) which would be 730 million rows.
So I would suggest doing something like the following where you check if the measure is not blank before adding the constant value to it.
GP per Lift (excluding rent & doc) = VAR _operationCost = 3 VAR _part1 = [Lift Rate] - [Disposal Cost per Lift] RETURN IF( NOT( ISBLANK( _part1 ) ), _part1 + _operationCost )
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.