π Bottom N Count Function
π Definition
The Bottom N Count function is used for:
β‘οΈ Counting (Count) the value of a field
β‘οΈ Retrieving N data with the SMALLEST count value
π The opposite of Top N Count
βοΈ Parameter
1. π― Field
Fields to be counted
Example:
2. π’ Number of Record (N)
The amount of data to be displayed (Bottom N)
Example:
- 3 β 3 smallest values
- 5 β 5 smallest values
3. π Ordered (Y/N)
- Y (Yes) β results are sorted (ascending / from smallest to largest)
- N (No) β results are not guaranteed
π Recommended: use Y for clear results
π₯ Input & π€ Output
Input
-
Previous result data (usually after GroupBy)
Output
The output will contain:
- All input fields
- New fields:
- Field grouping with postfix_new
- Sum result field
π§ How it works
Sample Data:
category views
------------------
A 100
A 200
B 300
B 100
C 50
Step 1: Count per category
category count_views
----------------------
A 2
B 2
C 1
Step 2: Bottom N (for example N=2)
category_new count_views
-------------------------
C 1
A 2
π§ͺ Case Study
π― Case:
Showing 3 categories with the LOWEST total count
π Workflow
- Source data
- GroupBy βcategory
- Bottom N Count:
- Field =views
- Number of Record =3
- Ordered =Y
π Output:
category_new count_views
--------------------------
Education 10
Travel 15
Music 20
π‘ Important Note:
The useful output fields from this buffer function are the grouped fields and new fields. Add a Transformator (

) assembly afterward to select these fields.