Forum Discussion
countrow when return zero or blank
- 4 years agoIn case if anyone is looking for solution, i did figure out1) first create measure to get total rows and return 0 if no rowsTotalRowsCount = IF (CALCULATE ( COUNTROWS('Table') ) = BLANK (),
0,CALCULATE ( COUNTROWS('Table') ))
2) create below measure to get the display
Total Rows = IF( ISFILTERED ('Table'[Search]) ,'Table'[TotalRowsCount] & " customer match(es) found.", "No customer match(es) found." )
Hi,
Try using ISBLANK. So something like this:
Total Rows = IF(ISFILTERED ('table'[Search]),
IF(ISBLANK(COUNTROWS('table') ), "No customer match(es) found.",
COUNTROWS('table') & " customer match(es) found.", "No customer match(es) found."))
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!
My LinkedIn: https://www.linkedin.com/in/n%C3%A4ttiahov-00001/
- sanjanarama4 years ago
Resolver I
ValtteriN
Too many arguments were passed to the IF function. The maximum argument count for the function is 3.
im getting above error when i use the dax- ValtteriN4 years ago
Community Champion
sanjanarama There was a problem with the brackects. Here is the modified verison:
IF(ISFILTERED ('table'[Search]),IF(ISBLANK(COUNTROWS('table') , "No customer match(es) found.",COUNTROWS('table') & " customer match(es) found.", "No customer match(es) found.")))- sanjanarama4 years ago
Resolver I
I'm sorry "Too many arguments were passed to the ISBLANK function. The maximum argument count for the function is 1."
this is error im seeing