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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
_google
Helper I
Helper I

7# lookup value with find/search within same fact table.

Hi

 

Reaching out for help to have lookup for below scenario in data table (which is within the data table). Not sure about how to manage in DAX ( PowerBI or PowerPivot)

 

my current excel formula Lookup(excel) =IFERROR(INDEX($B$3:$B$12,IF(ISNA(MATCH($C3,$D$3:$D$12,0)),MATCH("*"&$C3&"*",$D$3:$D$12,0),MATCH($C3,$D$3:$D$12,0))),"MV")

 

IFERROR(INDEX($Cntr Desc,IF(ISNA(MATCH($ID,Previous_ID,0)),MATCH("*"&$ID&"*",Previous_ID,0),MATCH($ID,Previous_ID,0))),"MV")

 

Basicually this help to identify ID is moveing or rotating in Cntrl centre.

 

Cntr DescIDPREVIOUS_IDLookup ( Excel)
RePack134892359875MV
Packing748987S773119DePacking
Packing278457488777DePacking
DePacking762675999841DMV
DePacking764309278457D-748987S-326506DMV
DePacking748987D748987MV
DePacking769547543065MV
PrePacking769561307417MV
PrePacking769939769952MV
PrePacking773119772727Packing
1 REPLY 1
Floriankx
Solution Sage
Solution Sage

Hello,

 

In PowerQuery you could load the Data twice.

First table: Cntr Desc, ID, PREVIOUS_ID

Second Table: Cntr Desc, ID

The second table you should filter dublicats.

 

Now you can 1. Continue in Power Query:

Append the tables matching PREVIOUS_ID and ID and expand Cntr Desc.

Afterwards you can replace Errors with 'MV'. This should lead to the expected result.

 

Or 2. go to PowerPivot

Load the tables to your data model. relate PREVIOUS_ID of first table with ID of second table.

A calculated column =RELATED(Table1[Cntr Desc]) should give you the correct result as well.

for Errors you can add ISERROR(RELATED(Table1[Cntr Desc]),'MV'

 

Best regards.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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