Enonic version: 6.8.0
Which make it kinda hard to filter by query on exact match…
Lets say country is stored as “Norway”.
Then query needs to be ‘data.country.name = “Norway”’
But aggregation country returns ‘norway’
So if I use the aggregation to build filter dropdowns on the website, I must somehow know that ‘norway’ means ‘Norway’.
I guess I could work around if by doing ‘data.country.name like “norway”’
But I also localize “Norway” to “Norge”. (using my own js structure built from a phrase contenttype)
And again ‘norway’ !== ‘Norway’;
I guess as long as people are involved I should suspect that any content field has inconsistencies in case.
In this instance data.country.name is populated via the content api.
So I could store values in lowercase.
I could also add a config regexp to the TextLine input which only accepts lowercase chars.
There might be future usecases where case sensitivity matters.
It should at least be documented that aggregations are case insensitive and returns lowercase version of whatever was stored.
But really should it not be possible to do case sensitive aggregations?