Replaced terms aggregation with cardinality aggregation for unique counts of a field