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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Jebilaya
Helper III
Helper III

Lookup Value error

I am trying to get a calculated column to return an alternative drop departure time.

 

I've created a column to give a unique route and drop ID for each row and I need to be able to return the planned departure time for the previous drop.  My lookupvalue formula is giving me a "A table of multiple values was supplied where a single value was expected." error

 

Any help appreciated

 

Jebilaya_0-1652947631363.png

 

1 ACCEPTED SOLUTION
Jebilaya
Helper III
Helper III

Resolved now - realised the uniqueID wasn't so unique so lookupvalue didn't work.

View solution in original post

5 REPLIES 5
SpartaBI
Community Champion
Community Champion

@Jebilaya just saw now that I missed your previuos reply. Sorry 🙂
Happy to see it was solved!

No worries - i'm new on my PowerBI journey so picking it up as I go.

 

I'm sure I will have other questions @SpartaBI  - this community is really helpful

Jebilaya
Helper III
Helper III

Resolved now - realised the uniqueID wasn't so unique so lookupvalue didn't work.

Jebilaya
Helper III
Helper III

 

Not sure how to supply sample data @SpartaBI  - can't see an attach option but i've put a table below

 

The DAX i'm trying to use is

PlanDepartPrior =
var dropprior = 'Microlise Files'[DropID]-1
Return
LOOKUPVALUE('Microlise Files'[Planned departure],'Microlise Files'[UniqueDrop],CONCATENATE('Microlise Files'[UniqueRoute],dropprior))

 

So basically drop 2 should return the departure time of drop 1

 

Order ReferenceActual arrivalActual departurePlanned arrivalPlanned departureUniqueDropDropIDExpected Result
10246575821899-12-30 06:47:001899-12-30 06:56:001899-12-30 06:43:001899-12-30 06:50:005/15/2022259-1011Blank
10250327181899-12-30 09:34:001899-12-30 09:46:001899-12-30 09:47:001899-12-30 09:58:005/15/2022259-1010101899-12-30 09:43:00
10052026231899-12-30 09:50:001899-12-30 10:03:001899-12-30 10:02:001899-12-30 10:15:005/15/2022259-1011111899-12-30 09:58:00
10249598271899-12-30 10:08:001899-12-30 10:15:001899-12-30 10:15:001899-12-30 10:31:005/15/2022259-1012121899-12-30 10:15:00
10250809631899-12-30 10:22:001899-12-30 10:27:001899-12-30 10:37:001899-12-30 10:42:005/15/2022259-1013131899-12-30 10:31:00
10248614531899-12-30 10:36:001899-12-30 10:42:001899-12-30 10:50:001899-12-30 10:58:005/15/2022259-1014141899-12-30 10:42:00
10239151931899-12-30 10:52:001899-12-30 10:59:001899-12-30 11:03:001899-12-30 11:28:005/15/2022259-1015151899-12-30 10:58:00
10243418881899-12-30 11:06:001899-12-30 11:10:001899-12-30 11:35:001899-12-30 11:42:005/15/2022259-1016161899-12-30 11:28:00
10249048121899-12-30 11:18:001899-12-30 11:30:001899-12-30 11:49:001899-12-30 12:00:005/15/2022259-1017171899-12-30 11:42:00
10247236571899-12-30 11:35:001899-12-30 11:43:001899-12-30 12:03:001899-12-30 12:12:005/15/2022259-1018181899-12-30 12:00:00
10238685911899-12-30 11:59:001899-12-30 12:05:001899-12-30 12:15:001899-12-30 12:23:005/15/2022259-1019191899-12-30 12:12:00
10243462271899-12-30 07:05:001899-12-30 07:17:001899-12-30 07:00:001899-12-30 07:19:005/15/2022259-10221899-12-30 06:50:00
10251122261899-12-30 07:40:001899-12-30 07:49:001899-12-30 07:21:001899-12-30 07:56:005/15/2022259-10331899-12-30 07:19:00
10248492291899-12-30 07:56:001899-12-30 08:01:001899-12-30 08:03:001899-12-30 08:10:005/15/2022259-10441899-12-30 07:56:00
10244315771899-12-30 08:03:001899-12-30 08:07:001899-12-30 08:11:001899-12-30 08:17:005/15/2022259-10551899-12-30 08:10:00
10251071931899-12-30 08:11:001899-12-30 08:13:001899-12-30 08:20:001899-12-30 08:27:005/15/2022259-10661899-12-30 08:17:00
10250569211899-12-30 08:18:001899-12-30 08:21:001899-12-30 08:31:001899-12-30 08:36:005/15/2022259-10771899-12-30 08:27:00
10248139741899-12-30 08:39:001899-12-30 08:55:001899-12-30 08:42:001899-12-30 08:52:005/15/2022259-10881899-12-30 08:36:00
10251040071899-12-30 09:18:001899-12-30 09:28:001899-12-30 09:33:001899-12-30 09:43:005/15/2022259-10991899-12-30 08:52:00

 

 

SpartaBI
Community Champion
Community Champion

@Jebilaya hey, it's really hard to see the details in the screenshot. Can you supply a sample data with the and an example of the desired result. 

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.

Top Solution Authors