Lookupvalue with multiple records

alirulez

New Member
Joined
Jul 4, 2015
Messages
35
Hi all

I need some help on PowerBI

Im trying to lookup a value from another table, except that other table has multiple rows with the same value that im looking up.

This ofcourse results in an error.

Each row has a 'createdon' date, so I thought it would be best to lookup the row with the earliest 'createdon' date.

So in short, i need a lookupvalue [or a summarize formula] which will lookup the 'customerid_account.name' column within the 'opportunity' table, and return the most recent 'statuscode' (also from within the opportunity table)

I hope this is clear. Ive tried various options but I cant seem to get it.

Thanks in advance
Ali
 

Excel Facts

Remove leading & trailing spaces
Save as CSV to remove all leading and trailing spaces. It is faster than using TRIM().
Hi Try this:

try a calculated column on Opportunity Table with this:
=
VAR Mydate =
CALCULATE (MIN ( AnotherTable[Date] ), FILTER ( CALCULATETABLE ( VALUES ( AnotherTable ) ), AnotherTable[Date] = Opportunity[CreatedOnDate]))
RETURN
CALCULATE (MIN ( AnotherTable[Value] ), FILTER ( CALCULATETABLE ( VALUES ( AnotherTable) ), AnotherTable[Date]= mydate ))
 
Last edited:
Upvote 0

Forum statistics

Threads
1,213,528
Messages
6,114,154
Members
448,553
Latest member
slaytonpa

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top