distinctCount
Last update: January 29, 2024
- Topics:
- Journeys
CREATED FOR:
- Experienced
- Developer
Counts the number of different values ignoring the null values.
Category
Aggregation
Function syntax
distinctCount(<listAny>)
Parameters
Parameter | Type | Description |
---|---|---|
listToProcess | listString, listBoolean, listInteger, listDecimal, listDuration, listDateTime, listDateTimeOnly, listDateOnly, or listObject | List to process. For listObject, it must be a field reference. |
keyAttributeName | string | This parameter is optional and only for listObject. If the parameter is not provided, an object is considered as duplicated if all the attributes have the same values. Otherwise, an object is considered as duplicated if the given attribute has the same value. |
Signature and returned type
distinctCount(<listAny>)
Returns an integer.
distinctCount(<listObject>)
distinctCount(<listObject>,<string>)
Returns a list of objects.
Example
distinctCount([10,2,10,null])
Returns 2.
distinctCount(@event{my_event.productListItems})
Returns the number of strictly distinct objects in the given array of objects (listObject type).
distinctCount(@event{my_event.productListItems}, "SKU")
Returns the number of objects which have a distinct “SKU” attribute value{}.
Previous pagecountWithNull
Next pagedistinctCountWithNull
Journey Optimizer
- Journey Optimizer documentation
- What’s new?
- Get started
- Journeys
- Campaigns
- Conflict management & prioritization
- Test & approve
- Communication channels
- Get started with communication channels
- Email channel
- In-app channel
- Push notification channel
- SMS / MMS channel
- Direct mail
- Web channel
- Code-based experience
- Content cards
- Landing pages
- Content management
- AI Assistant for content generation
- Work with Multilingual content
- Work with Content experiment
- Personalization
- Content templates
- Reusable content fragments
- Dynamic content
- Audiences, profiles & identity
- Integrations
- Track & monitor
- Live report
- All time report
- Journey reports
- Deliverability
- Alerts
- Exclusion reasons
- Decision capabilities
- Get started with decision capabilities
- Decisioning
- Get started with Decisioning
- Decisioning guardrails & limitations
- API reference
- Manage decision items
- Configure item selection
- Create selection strategies
- Create decision policies
- Report on Decisioning
- Decisioning use case
- Decision management
- Get started with Decision management
- Create components
- Create rankings
- Create & manage offers
- Create & manage decisions
- Use batch decisioning
- Collect event data
- Leverage context data
- Create Decision Management reports
- Export your offer catalog
- API Reference
- Getting started
- Create & manage offers using APIs
- Deliver offers using APIs
- Data management
- Configuration
- Get started with Journey Optimizer configuration
- Set up channel configurations
- Guided channel setup
- Delegate email subdomains
- Implement an IP warmup plan
- Monitor email addresses
- Use seed lists
- Support for archiving
- Change execution addresses
- Work with rule sets
- Configure journeys
- Sources
- Export objects to another sandbox
- Access control
- Privacy