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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
wdrain
Helper I
Helper I

Help with a DAX caculate column

Help I can't figure the correct dax formula to return the "Lastest Packaged Version" from the Packaged Software table in my Dax formula shown below. I have the Latest Packaged Version currently hard coded  with

0073.0000.3683.0086" as shown below. 
 
I need like to replace this value with a DAX formula of the value of Lastest Package Version from the Package Software table.
 
Any Assistance would be greatly appreciated 
 
ThanksUpgrade status.png

 

 
 

 

The InstalledSoftware and PackagedSoftware are related and I have it correctly displayed in column 4. 

6 REPLIES 6
Anonymous
Not applicable

If you can sort the the specific column and use the DAX formula LASTNONBLANKS(<Table>,1) it should work.  All the best.

Regards

 

LW,

 

Thanks for the quick reply, Unfortunely the LastNONBLANK function did'nt work. The Upgrade Status value returned True for all the values. Any other recommendations ?

 

 

Upgrade status.png

 

The Latest Pkg_Version =
CALCULATE(
VALUES( InstalledSoftware[Version_Normalized]),
FILTER(ALL( InstalledSoftware[Version]), InstalledSoftware[Version] = LASTNONBLANK('Packaged Software'[Latest Packaged Version],1)
))
 
did return the last normalized Version but when this formula is plugged into my IF then statement for the Upgrade status all the values return true.
 
Upgraded Status =
IF (InstalledSoftware[Version_Normalized] >= CALCULATE(
VALUES( InstalledSoftware[Version_Normalized]),
FILTER(ALL( InstalledSoftware[Version]), InstalledSoftware[Version] = LASTNONBLANK('Packaged Software'[Latest Packaged Version],1)
)) ,
//"0073.0000.3683.0086",
"Upgraded", "Not Upgraded")
 
 
 
Anonymous
Not applicable

You might need to do step by step approach rather adding everything in one formula.

 

1. try to filter out the latest first - create a column

     i.e.  MaxVersion = CALCULATE(FILTER(yourtablename[Name]=EARLIER(yourtablename[Name]))

2. Create a column called status

   IF(installedSoftware[Version_Normalized] >= MaxVersion, "Upgraded", "Not Upgraded")

 

Thank you.

Hi LW thanks for the suggestion.

I think it got me closer but it still does not work! 

I attempted get the Max version using the formula as you suggested but was not able to get it work ...

 

MaxVersion = CALCULATE(FILTER(yourtablename[Name]=EARLIER(yourtablename[Name])) 

 

So I created a another formula that does provide the normalized version of the Latest package version, as shown below...

 

MaxVersion = CALCULATE(
VALUES( InstalledSoftware[Version_Normalized]),
FILTER(ALL( InstalledSoftware[Version]), InstalledSoftware[Version] = LASTNONBLANK('Packaged Software'[Latest Packaged Version],1)
))
 
However when this value is referenced  in the Upgrade Status calculated formula I can the error messsage
"A circular dependency was detected:"  as shown below. Would you know how I can get past this error message ?
Upgrade status.png

 

 

Anonymous
Not applicable

Hi @wdrain 

 

I'm going to assume thats because it's not a number and therefore can't be compared with. It looks like it's text.

 

I've tried to import something similar to you and it comes in as text and Power BI is unable to convert it to any kind of number.

Helpful resources

Announcements
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!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

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.