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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
jk13
Frequent Visitor

How to Lookup a value from a filtered table

Hi all,

 

i have the following data structure tables:

 

requests

request_id name
1

james

2rob
3sam

 

activities

activity_id request_id event      date
11CREATE2022-01-10
21UPDATE2022-01-12
32CREATE2022-01-12

 

I want to add a column "create_date" to the requests-table with the date from the activities where the event is CREATE.

 

There is a one-to-many relationship between requests and activities.

 

I know this should not be that hard, but somehow i struggle to come op with an easy solution. My idea was using lookupvalue based on the filtered activities-table.

 

Thanks for your help!

1 ACCEPTED SOLUTION
Samarth_18
Community Champion
Community Champion

Hi @jk13 ,

 

Create column with below code:-

create date = 
CALCULATE(
    MAX(activities[date]),
        activities[event] = "CREATE"
)

Output:-

Samarth_18_0-1641978701116.png

 

 

Thanks,

Samarth

Best Regards,
Samarth

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin

View solution in original post

1 REPLY 1
Samarth_18
Community Champion
Community Champion

Hi @jk13 ,

 

Create column with below code:-

create date = 
CALCULATE(
    MAX(activities[date]),
        activities[event] = "CREATE"
)

Output:-

Samarth_18_0-1641978701116.png

 

 

Thanks,

Samarth

Best Regards,
Samarth

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
Connect on Linkedin

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.