Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
sakshikaul
Helper III
Helper III

To write a measure in Power Bi

Hi, I am migrating qlikview to Power Bi. I have following expression in qliview that needs to be converted in Power BI

((SUM(IF(Mode_group_3 = 'AirImport',[ChglWt(KG)],0)))/1000)   How to write above expression in Power BI.   

3 REPLIES 3
Anonymous
Not applicable

can you tell me .what exactly output this function will give you so it will help me to understand .

 

what i understood is 

 

((SUM(IF(Mode_group_3 = 'AirImport',[ChglWt(KG)],0)))/1000)

 

when mode group 3 = Airimport then sum chglwt(kg) then divide it from 1000 . if its correct then 

you can use below formula 

 

measure = calculate(sum([ChglWt(KG)]),Mode_group_3 = 'AirImport")

or you can use this as well if you want to divide with 1000 then use below formula 

 

measure = calculate(divide(sum([ChglWt(KG)]),1000,0),Mode_group_3 = 'AirImport")

this will give you sum of [ChglWt(KG)] then divide it from 1000 .

 

 

 

 

 

This is fgiving me following error 

error.png

Anonymous
Not applicable

you Need to remove extra bracket from the formula and kindly use " " excat same field from data in " " (which you want to filter).

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.