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

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

Reply
Anonymous
Not applicable

Help creating Column by Phase and scan date

Hello everyone, 

 

Im needing help creating a formula that will look at a certain uploaded phase date by department #. Basically what i have is certain phases that were changed on a upload date. I am wanting to look at a units scan date by department and have it return what phase this unit was a part of. One sheet contains information as follows:

 

Department     Upload on       Phase 

ABC                   4/6/18               1

ABC                   5/9/19               2

ABC                   7/12/19             3

 

 

The other sheet contains the information of :

 

Department                 Scan Date

ABC                               9/5/18

ABC                               5/10/19

 

Im needing it to return a value of which Phase this product would have belonged to. Please help!!!

1 ACCEPTED SOLUTION
v-xicai
Community Support
Community Support

Hi @Anonymous ,

 

You can create column Phase_matched to meet your demand.

 

Phase_matched =
MAXX (
    TOPN (
        1,
        FILTER (
            Table1,
            Table1[Department] = Table2[Department]
            && Table1[Upload on] <= Table2[Scan Date]
        ),
        Table1[Upload on], DESC
    ),
    Table1[Phase]
)

 

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
v-xicai
Community Support
Community Support

Hi @Anonymous ,

 

You can create column Phase_matched to meet your demand.

 

Phase_matched =
MAXX (
    TOPN (
        1,
        FILTER (
            Table1,
            Table1[Department] = Table2[Department]
            && Table1[Upload on] <= Table2[Scan Date]
        ),
        Table1[Upload on], DESC
    ),
    Table1[Phase]
)

 

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

dethompson97
Resolver III
Resolver III

I'm not sure that I understand the issue.  Can you please provide the desired output based on the input you have listed.

 

Thanks!

Dawn

Anonymous
Not applicable

Yes the top one would give me Phase 3 and the bottom Phase 2

Anonymous
Not applicable

So anything scanned from upload date on Phase 1 until Upload date on Phase 2 would be a Phase 1 product and so on

 

Helpful resources

Announcements
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 Kudoed Authors