[SERVER-30602] provide a simple $eq (binary, lexical) expression for comparison independent of collation Created: 10/Aug/17  Updated: 06/Dec/22  Resolved: 20/Apr/18

Status: Closed
Project: Core Server
Component/s: Aggregation Framework, Querying
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Asya Kamsky Assignee: Backlog - Query Team (Inactive)
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Assigned Teams:
Query
Participants:

 Description   

It's possible that one needs to make binary/simple comparison of two fields even in the context of a collection/operation with non-simple collation.

In match language it can be faked by using left and right anchored regex, but there is no way to do this in aggregation. Having some kind of "$binEq" expression would provide it for aggregation (and if it's available in match that would also be useful).



 Comments   
Comment by Ian Whalen (Inactive) [ 14/Aug/17 ]

We're going to delay decision on this particular implementation pending review of the discussion above and how we want to solve that problem. The more complete solution would be per-predicate collations.

Comment by Asya Kamsky [ 10/Aug/17 ]

This came up related to dynamic view definitions, since we can have two usernames (or roles) that differ only by case or secondary characteristic and would compare equal with some collations, we need a way to compare usernames that's not collation sensitive regardless of default collation of underlying collection/view.

Generated at Thu Feb 08 04:24:23 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.