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
nemo
Helper I
Helper I

What is the correct parameter type for ALL?

I created this measure to test how context evaluation worked:

 

Last Non-blank =
LASTNONBLANK (
'Date'[Date],
CALCULATE ( COUNTROWS ( Sales ), ALL ( Product ) )
)
 
However, I got an error message saying that Product was not the correct parameter type (please see the screen shot).
Capture.PNG
 
Could someone please explain the meaning of that error message?
1 ACCEPTED SOLUTION

Hi @nemo ,

 

Keep Product in single quotes 'Product'.

It is giving an error because Product is one of the built in function in Power BI.

 

Please try it and let me know if that works for you.

 

Best regards,

Pooja Darbhe

View solution in original post

4 REPLIES 4
PoojaDarbhe
Resolver I
Resolver I

Hi @nemo ,

 

Please check whether you have relationship between Sales and Product tables, if that exist then only it will work, if not please create a relationship first then try.

 

Best regards,

Pooja Darbhe

Thanks @PoojaDarbhe for your quick response. The model did have a relationship between Product and Sales as shown below Capture.PNG

Hi @nemo ,

 

Keep Product in single quotes 'Product'.

It is giving an error because Product is one of the built in function in Power BI.

 

Please try it and let me know if that works for you.

 

Best regards,

Pooja Darbhe

Excellent. Thanks @PoojaDarbhe

Intellisense seemed not that inteligent: it should have simply spelt out that Product was a reserved keyword 😉

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.

Top Solution Authors