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! Request now

Reply
tjlundquist1
Helper I
Helper I

Rank values of one column based on Date

Trying to find a solution to rank people based on the date they were added to a Line#

Below, you can see the Line # column is the same for this example and there are 4 people attached to this Line#. In the 'Date Assinged to Role' column identifies when they were added to this Line#. 

tjlundquist1_1-1645459462720.png

I am wanting to add a column to rank the 'Adjuster' column 1-X based on the 'Date Assinged to Role' column all linking to the 'Line #' column. 1 being the earliest date. There are 10's of 1,000's of Line #'s. Want to be able to see by Line #, who was on it and what order were they added.

 

Here's the desired result

tjlundquist1_2-1645460099622.png

 

Thanks!

 

 

1 ACCEPTED SOLUTION
tackytechtom
Super User
Super User

Hi @tjlundquist1 ,

 

I got to this solution here:

tomfox_0-1645469979948.png

 

This is the DAX code I used:

Order added to Role = 
RANKX ( 
    FILTER ( 
        Table29, 
        Table29[Line #] = EARLIER ( Table29[Line #] )
    ),
    Table29[Date assigned to Role],
    ,ASC
    ,Dense
)

 

Does this get you closer to a solution? 🙂

 

/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/



Did I answer your question➡️ Please, mark my post as a solution ✔️

Also happily accepting Kudos 🙂

Feel free to connect with me on LinkedIn! linkedIn

#proudtobeasuperuser 

View solution in original post

2 REPLIES 2
Ashish_Mathur
Super User
Super User

Hi,

Try this calculated column formula:

=calculate(countrows(data),filter(data,data[line #]=earlier(data[line #])&&data[date assigned o role]<=earlier(data[date assigned o role])))

Hope this helps.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
tackytechtom
Super User
Super User

Hi @tjlundquist1 ,

 

I got to this solution here:

tomfox_0-1645469979948.png

 

This is the DAX code I used:

Order added to Role = 
RANKX ( 
    FILTER ( 
        Table29, 
        Table29[Line #] = EARLIER ( Table29[Line #] )
    ),
    Table29[Date assigned to Role],
    ,ASC
    ,Dense
)

 

Does this get you closer to a solution? 🙂

 

/Tom
https://www.tackytech.blog/
https://www.instagram.com/tackytechtom/



Did I answer your question➡️ Please, mark my post as a solution ✔️

Also happily accepting Kudos 🙂

Feel free to connect with me on LinkedIn! linkedIn

#proudtobeasuperuser 

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.

Top Solution Authors