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
Anonymous
Not applicable

Data Export to Excel Not Correct

The goal is to export data which has a ratio. Problem is that the visual will correctly display the ratio but when exported, excel will generate the value as a date. The measure creating this ratio was formatted to be used as a KPI. The column's format for the exported data = "Custom". I tried playing around with the format by changing it to "General / Number / Text" but that did not resolve the issue. For context, below you will find the following: Ratio Measure /  Current Output / Expected Output

 

Not sure on how to remedy this but your advice is greatly appreciated.

 

Ratio Measure

 

sold_inventory_ratio =
IF( 
    TRUE()
    ,FORMAT([item_sold],"0,0") & " / " & FORMAT([item_inventory],"0,0")
    // ,FORMAT(VALUE([item_sold]),"0,0") & " / " & FORMAT(VALUE([item_inventory]),"0,0")
    // -- I also tried the above commented measure with FORMAT + VALUE but it was giving me the same output when exporting this ratio
    , 1
)

 

 

Current Output: Notice column [sold_inventory_ratio] >> Some values are ratios but some are listed as dates which is not correct

item_iditemitem_solditem_inventorysold_inventory_ratio
1Pizza155415 / 54
2Burgers548May-48
3Tacos1246Dec-46
4Sushi145Jan-45
5Salad315131 / 51

Expected Output: Notice column [sold_inventory_ratio] >> The ratios are correctly displayed

item_iditemitem_solditem_inventorysold_inventory_ratio
1Pizza155415 / 54
2Burgers54805 / 48
3Tacos124612 / 46
4Sushi14501 / 45
5Salad315131 / 51
1 ACCEPTED SOLUTION
Anonymous
Not applicable

I was able to find a resolution by updating the measure from " / " to " of "

sold_inventory_ratio =
FORMAT(VALUE([item_sold]),"0,0") & " of " & FORMAT(VALUE([item_inventory]),"0,0")

 

View solution in original post

4 REPLIES 4
Anonymous
Not applicable

I was able to find a resolution by updating the measure from " / " to " of "

sold_inventory_ratio =
FORMAT(VALUE([item_sold]),"0,0") & " of " & FORMAT(VALUE([item_inventory]),"0,0")

 

Anonymous
Not applicable

Hi @Anonymous ,

 

What is the Data Type of this column in Power BI Desktop?

Could you try changing it to Text Type then exporting again?

 

Best Regards,

Jay

Anonymous
Not applicable

@Anonymous I updated the measure and the data type is now Text. Unfortunately, I am still getting the same result for the data export. The export will result in some values reflected as Dates (just like in the example listed above). 

 

Any advice on how I can remedy this? Your advice is greatly appreciated. 

 

sold_inventory_ratio =
FORMAT(VALUE([item_sold]),"0,0") & " / " & FORMAT(VALUE([item_inventory]),"0,0")
Anonymous
Not applicable

@Anonymous the data type in Power BI Desktop for this measure was General. I tried to update it to Text but for some reason the data type is not changing. Any advice on how I can change the measure data type to Text? 

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.

Top Solution Authors
Top Kudoed Authors