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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
pedrogom
Frequent Visitor

Lookupvalue: <searchvalue> is a value in the current row

Hi everyone! I'm new at PBI.

 

Can anyone help me use the function LOOKUPVALUE?

 

Here's the deal:

 

I'm creating a calculated column in a table named "tbl_ocioso" which is related (many to one) to the table "DM_PRINTERDEVICE" by the id of the printer device ([SK_PRINTERDEVICE]).

 

The calculated column has to bring me the value of the column "Alvo min" of the register related to the printer device related to the current row. The images bellow give a better idea of what I'm trying to do:

Dax syntax error codeDax syntax error code

 

I tried the following dax code:

AlvoMinimo = LOOKUPVALUE(DM_PRINTERDEVICE[Alvo min];DM_PRINTERDEVICE[SK_PRINTERDEVICE];tblOcioso[SK_PRINTERDEVICE])
However, I got the following error message:
"A circular dependence was detected: tblOcioso[ImpressoesCopiasTotal], tblOcioso[AlvoMinimo], tblOcioso[ImpressoesCopiasTotal]"
 
Is that the right way to get the result? What am I doing wrong?
 
Thanks!
1 ACCEPTED SOLUTION
pedrogom
Frequent Visitor

Guys, I got the desired result with another DAX function: RELATED:

 

AlvoMinimo = RELATED(DM_PRINTERDEVICE[Alvo min])

Worked out fine!

 

View solution in original post

2 REPLIES 2
pedrogom
Frequent Visitor

Guys, I got the desired result with another DAX function: RELATED:

 

AlvoMinimo = RELATED(DM_PRINTERDEVICE[Alvo min])

Worked out fine!

 

pedrogom
Frequent Visitor

Here is the image missing, which shows the relationship between the tables (the key field is called [SK_PRINTERDEVICE]): relationships-value-lookup-doubt.PNG

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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