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

Re: How to remove duplicate row counts after grouping

$
0
0

Hi Abhilash,

 

Sorry I'm a little confused and probably doing something wrong or a missing a step. Here they are:

 

1. Create a new SQL expression field "Total_Items" with the following formula:

 

(

Select Count (T."field") from Table T

)

 

2. Use the formula:

 

Count ({Items})/{% SQL Expression}

 

However, I cannot use the formula in the first step since I do not have a field in the table that I can count. "Age" is a custom field that is calculated by using the following formula: Age = (currentdate - 1) - {Table.Service_Date}

 

Without the Age > 30 record selection filter, I get back 793 records, and with this filter turned on I get 12 records back. Hence the compliance rate formula should be 12/793 = 1.51%

 

Can you please let me know what I maybe missing?


Viewing all articles
Browse latest Browse all 8451

Trending Articles



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