Forum Discussion
Syntax assistance with a Filter that has multiple AND / Or conditions
Good Day
I need some assistance with Syntex for the below section in RED not sure if this should be a AND / OR / included in List
this is a straight Row Count based on the below conditions being found. TY for your assistance
--------------------------------
__Testing VAR _count =
COUNTROWS ( FILTER (FILTER ( FILTER (
'_Rack Metrics Report',
'_Rack Metrics Report'[Site] = "123XXX"),
'_Rack Metrics Report'[DisplayLabel] = "Live")
FILTER ('_Rack Metrics Report',
'_Rack Metrics Report'[_All Rack Conditions] = "Installed Client Used")
OR( '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Powered Available")
OR( '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Not Powered")
- Anonymous1 year ago
Hi EZimmet ,
I create a table as you mentioned and use your DAX codes, it gives me the same error.
So I think you can change your DAX code and here is the DAX code:
Testing VAR _count = COUNTROWS ( FILTER ( FILTER ( FILTER ( '_Rack Metrics Report', '_Rack Metrics Report'[Site] = "123XXX" ), '_Rack Metrics Report'[DisplayLabel] = "Live" ), '_Rack Metrics Report'[_All Rack Conditions] = "Installed Client Used" || '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Powered Available" || '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Not Powered" ) )Best Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
4 Replies
- Syk
Resident Rockstar
It depends what you're trying to achieve in your logic but if you're just trying to fix whats in red...
test = FILTER ('_Rack Metrics Report', '_Rack Metrics Report'[_All Rack Conditions] = "Installed Client Used" || '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Powered Available" || '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Not Powered" )- EZimmet
Resolver I
Receiving error:The expression refers to multiple columns. Multiple columns cannot be converted to a scalar value.__Testing VAR _count =COUNTROWS ( FILTER (FILTER ( FILTER ('_Rack Metrics Report','_Rack Metrics Report'[Site] = "Downers Grove"),'_Rack Metrics Report'[DisplayLabel] = "Live"),FILTER ('_Rack Metrics Report','_Rack Metrics Report'[_All Rack Conditions] = "Installed Client Used"|| '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Powered Available"|| '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Not Powered")))- AnonymousNot applicable
Hi EZimmet ,
I create a table as you mentioned and use your DAX codes, it gives me the same error.
So I think you can change your DAX code and here is the DAX code:
Testing VAR _count = COUNTROWS ( FILTER ( FILTER ( FILTER ( '_Rack Metrics Report', '_Rack Metrics Report'[Site] = "123XXX" ), '_Rack Metrics Report'[DisplayLabel] = "Live" ), '_Rack Metrics Report'[_All Rack Conditions] = "Installed Client Used" || '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Powered Available" || '_Rack Metrics Report'[_All Rack Conditions] = "Installed Empty Not Powered" ) )Best Regards
Yilong Zhou
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.