Normal method to get the distinct values,
SELECT COUNT(DISTINCT(customer_name)) FROM table_name;
Using estimation function,
SELECT HLL(customer_name) FROM table_name;
Benchmark: For 150,000,000 rows
- Normal method took, 12s
- Estimation function took, 5.6s
No comments:
Post a Comment