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

Return column result from a search text string

New to Powerbi and lots of really useful contact in previous posts.

 

I would usually use LOOKUPVALUE to search for a booking ID in a separate table and return the created time. This time though the table where I am searching has multiple lines for the same BookingID. I am looking for the created time only for the line when it has a particular text string within the description column as in row2 (....Internal system). 

Shall871_0-1602333305472.png

Thanks in advance

1 ACCEPTED SOLUTION
DataInsights
Super User
Super User

@Shall871,

Try this calculated column:

Created Date = 
VAR vBookingID = BookingMain[Booking ID]
VAR vBookingDetails =
    FILTER (
        BookingDetail,
        BookingDetail[Booking ID] = vBookingID
            && CONTAINSSTRING ( BookingDetail[Description], "Internal System" )
    )
VAR vResult =
    MAXX ( vBookingDetails, BookingDetail[Created Date] )
RETURN
    vResult





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

2 REPLIES 2
DataInsights
Super User
Super User

@Shall871,

Try this calculated column:

Created Date = 
VAR vBookingID = BookingMain[Booking ID]
VAR vBookingDetails =
    FILTER (
        BookingDetail,
        BookingDetail[Booking ID] = vBookingID
            && CONTAINSSTRING ( BookingDetail[Description], "Internal System" )
    )
VAR vResult =
    MAXX ( vBookingDetails, BookingDetail[Created Date] )
RETURN
    vResult





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Anonymous
Not applicable

Perfect thanks

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