Count of Distinct in Backend

Is there a way in the Backendless console to get the count of records having a distinct value in one or more columns? Thanks.

Yes, there is.

Sample data (Cities with corresponding districts):

REST Console:

More complete where clause (the having clause is optional - I used to demonstrate the capabilities to filter aggregated data):

/data/City?
   property=District&
   property=Count(objectId) as citiesInDistrict&
   groupBy=District&
   having=citiesInDistrict > 5

Codeless version: