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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
MidiGlitch
Frequent Visitor

LOOKUPVALUE not supported in DirectQuery. Is there a work around??

Hi:

 

Am trying to implement an expotential smoothing calc to a line graph and need to access the previous row's data. When trying to add a calculated column LOOKUPVALUE is said to be unsupported, so am looking for an alternative way to get the previous row's data. My table has an index that I can use.

 

Ideally I want to do something like:

 

 

ExpotSmooth = IF(
    Tab[Index] = 1, 0,
        IF(
           Tab[Index] = 2, LOOKUPVALUE(Tab[FPS], Tab[Index], Tab[Index-1]),
                 LOOKUPVALUE(Tab[FPS], Tab[Index], Tab[Index-1]) * 0.1 + LOOKUPVALUE(Tab[ExpotSmooth], Tab[Index], Tab[Index-1]) * 0.9
        )
    )

 

Thx

 

1 REPLY 1
v-caliao-msft
Employee
Employee

@MidiGlitch,

 

Yes, we cannot use this function when connect to database by using directquery mode. To work around this issue, you'd better create such a column in your database. And then connect to this database in Power BI. 

 

Thank you for your understanding.

 

Regards,

Charlie Liao

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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