Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I am looking for hlep please. Apologies if it has been asked already.
I have 3 tables, each with a Product Name column, i have created relationships between them all.
I need to look up the 'Product Name' (A column), if matched in Table 2 (D column), then populate 'Owner' (B column) with the 'Cost Centre'. If it doesn't exist in Table 2 then check table 3. If it doesn't exist in Table 3 then populate 'Owner' as "N/A".
Solved! Go to Solution.
Hi @TAD80 can you try this formula
= IF (
NOT ( ISBLANK ( LOOKUPVALUE ( Table2[Product Name], Table2[Product Name], [Product Name] ) ) ),
LOOKUPVALUE ( Table2[Cost Centre], Table2[Product Name], [Product Name] ),
IF (
NOT ( ISBLANK ( LOOKUPVALUE ( Table3[Product Name], Table3[Product Name], [Product Name] ) ) ),
"N/A",
""
)
)
The above formula checks if the ‘Product Name’ exists in Table 2. If it does, then it populates the ‘Owner’ column with the corresponding ‘Cost Centre’.
If it doesn’t exist in Table 2, then it checks if it exists in Table 3.
If it does, then it populates the ‘Owner’ column with “N/A”.
If it doesn’t exist in either table, then it leaves the ‘Owner’ column blank.
Please let me know if this work.
Thanks
@TAD80 you can modify the formula to ensure that it correctly handles data from Table 3.
= IF (
NOT ( ISBLANK ( LOOKUPVALUE ( Table2[Product Name], Table2[Product Name], [Product Name] ) ) ),
LOOKUPVALUE ( Table2[Cost Centre], Table2[Product Name], [Product Name] ),
IF (
NOT ( ISBLANK ( LOOKUPVALUE ( Table3[Product Name], Table3[Product Name], [Product Name] ) ) ),
LOOKUPVALUE ( Table3[Department Name], Table3[Product Name], [Product Name] ),
"N/A"
)
)
Note:
if the "Product Name" is not found in Table 2, it checks Table 3 for the same value.
If it exists in Table 3, it populates the "Owner" column with the corresponding "Department Name" from Table 3.
If it doesn't exist in either table, it sets "Owner" to "N/A."
Please let me know if this works
Thanks
@DallasBaba Thanks very much for your response. That nearly works, it is pulling in from one table but not correctly pulling in the data from Table 3. For example, it should have pulled in a department name for ikj-hgf-456.
Hi @TAD80 can you try this formula
= IF (
NOT ( ISBLANK ( LOOKUPVALUE ( Table2[Product Name], Table2[Product Name], [Product Name] ) ) ),
LOOKUPVALUE ( Table2[Cost Centre], Table2[Product Name], [Product Name] ),
IF (
NOT ( ISBLANK ( LOOKUPVALUE ( Table3[Product Name], Table3[Product Name], [Product Name] ) ) ),
"N/A",
""
)
)
The above formula checks if the ‘Product Name’ exists in Table 2. If it does, then it populates the ‘Owner’ column with the corresponding ‘Cost Centre’.
If it doesn’t exist in Table 2, then it checks if it exists in Table 3.
If it does, then it populates the ‘Owner’ column with “N/A”.
If it doesn’t exist in either table, then it leaves the ‘Owner’ column blank.
Please let me know if this work.
Thanks
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
26 | |
10 | |
10 | |
9 | |
6 |