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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
ssbagley
Helper III
Helper III

Keywords Lookup - DirectQuery

I have a table of keywords and want to search the Expenses[Description] column and return results either in a column or filtered table of all rows containing the keyword.

This calculated column works great in my Sample data, but my live data is Direct Query and I cannot add this column.  Any thoughts on making it work with Direct Query?

Sample: https://drive.google.com/file/d/1OBH19U2hwxf1lj2_l-po3Wo2y-2mmE1K/view?usp=share_link

 

Filter =
VAR Keywords =
    FIRSTNONBLANK (FILTER (VALUES ( 'Table'[Keywords] ), SEARCH ( 'Table'[Keywords], Expenses[Description], 1, 0 )),1)
RETURN IF ( NOT ( ISBLANK ( Keywords ) ), Keywords, "" )
1 REPLY 1
amitchandak
Super User
Super User

@ssbagley , Create a measure like

maxx(filter('Table', SEARCH ( 'Table'[Keywords], Expenses[Description], 1, 0 )>0), 'Table'[Keywords] )

 

plot with Keywords

 

Countx(filter('Table', SEARCH ( 'Table'[Keywords], Expenses[Description], 1, 0 )>0), 'Table'[Keywords] )

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.