I have a workbook with a numeric column that may have repeating values:
1
1
2
3
3
3
I’d like to create a filter to only display rows based on how many times the column is duplicated. Something like a filter on count(unique(col)) where I could pick 1, which would only show the single row “2”, or 2, which would show both of the rows with “1”.
Is it possible to this?
Response
Sachin Prakash over 7 years ago
Hi Jason,
We’ve recently introduced Count Distinct functionality in a patch. However, it is not supported in filters yet. We’ll have a patch by monday w/ Filter support. If you’re interested, below is a download link.
Download link: http://www.aquafold.com/download/v17.0.0/ads-17.0.3-6-patch.zip
Update Instructions: http://www.aquafold.com/support-update.html#v17
Screenshots showing how to use it: https://www.aquaclusters.com/app/home/project/public/aquadatastudio/issue/14265
Using the existing CountD functionality, you can still address your use case by creating field as shown here & then drag the calculated field into the filter.
I’ll update this Q&A once the patch w/ filter support is ready.
Jason Klapste over 7 years ago
Awesome and perfect timing! Thanks for the detail!
Sachin Prakash over 7 years ago
Hi Jason,
We have a new build w/ support for COUNT DISTINCT filter. However, I don’t think it will address your use case. Let me illustrate w/ some screenshots.
Take a look at the DataSet screenshot. This is my “raw” data.
I’ve set my count filter to “2” : CountFilter screenshot. Only 1 record for “A” is displayed but you’d like to see 2 records, as shown in this “view data” screen : ViewData screenshot. I’m assuming that you don’t want to have to click on “view data” to see the 2 records, is that correct? If so, can you describe your use case further. Are you looking to plot this data as a table or a bar chart or …?
Attachments(4).zip
Jason Klapste over 7 years ago
Good question. In my current case (that I was working on last week), I was only showing the single row for any duplicates, i.e. what you are seeing on the workbook. I was doing some deeper dives on some of those rows in which case using the underlying data functionality is exactly what I needed.
BUT I can also see cases where you’d want to show both “A” rows– but that feels to me like some other calculated field/filter