Forum Discussion
lookup value from table
Hello,
I am new to this forum and fairly new to Power BI
I am trying to lookup value from table service with a coloumn id_operation. relation of both table is coloumn vincode.
how to lookup value with category id_operation values "1" in coloumn data ?
Following is a table :
please help for my case.
thanks.
Hi@ ranggafirmansya
When you add a column, It returns values must be one.
You need to add another condition:
SERVICE[ID_OPERATION]=1
data = LOOKUPVALUE(SERVICE[date],SERVICE[VINCODE],CUSTOMER[VINCODE],SERVICE[ID_OPERATION],1)
Result:
Best Regards,
Lin
4 Replies
- v-lili6-msftCommunity Support
Hi@ ranggafirmansya
When you add a column, It returns values must be one.
You need to add another condition:
SERVICE[ID_OPERATION]=1
data = LOOKUPVALUE(SERVICE[date],SERVICE[VINCODE],CUSTOMER[VINCODE],SERVICE[ID_OPERATION],1)
Result:
Best Regards,
Lin
- ranggafirmansyaRegular Visitor
thanks for your answer Mr. Lin :smileyvery-happy:
- mmace1Impactful Individual
LOOKUPVALUE is the function you probably want.
I think it's easiest to just start typing data = LOOKUPVALUE( and follow the tooltips, but in the end you will use something like this:
Data =LOOKUPVALUE(Service[ID_OPERATION],Service[VinCode],WhateverThisTableNameIs[Vincode])
- ranggafirmansyaRegular Visitor
I have tried according to your suggestion, but I found the following error:
what's the solution ?