Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 8578

Rank() function not considering Null values as 0

$
0
0

I have table where I show employees and breakup of their billable time, Non-Billable time and Leaves/Holiday. I needed the ability to sort the table by any of the fields so I used the technique described in the link below (mainly using Rank function) and achieved that.

 

Dynamic Sorting in WebIntelligence report

 

However, I noticed that when I sort by say Billable and ascending (Low to High), all the employees with 0 or NULL billable time don't show up at the top. It starts with whoever has at least 1 billable hour.

 

I need the ones that have no billable hours to show up at the top i.e. null should be considered as zero.

 

I was able to work around it by making the billable values zero when null. Now the problem is that the report will show zeros all through the report whenever there is null and that makes it a tad more difficult to read. I could apply conditional formatting and make font color same as background but my table has alternate row colors so the zero will show up in alternate shows.

 

Is there a better way to handle this problem?


Viewing all articles
Browse latest Browse all 8578

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>