Feature Request P2
Status Update
Comments
mo...@homedepot.com <mo...@homedepot.com> #2
Can you please help share the idea.log file (select Help > Show Log in Finder/Explorer) if this issue reproduces again? Thank you very much!
Description
This will create a feature request which anybody can view and comment on.
Please describe your requested enhancement. Good feature requests will solve common problems or enable new use cases.
What you would like to accomplish: Customer would like to have the capability to perform case-insensitive queries by string property value. Currently, Firestore's EQUAL operator only returns entity/documents where the property values match exactly with the value from the query.
How this might work: Customers will be able to use case insensitive while filtering documents with specific fields
If applicable, reasons why alternative solutions are not sufficient: To accomplish the equivalent in Firestore, one would have to create a separate property to store the normalized value of the property, and maintain the normalized property during subsequent updates of the non-normalized property of a document.
mongoDB supports Case Insensitive Indexes, where queries can lookup documents with matching properties regardless of case. A similar feature would allow fast document lookup (without having to scan the entire index) while tolerating case mismatches in the query.
Other information (workarounds you have tried, documentation consulted, etc):
To support case-insensitive or any other canonicalization you'll need to write a separate field that contains the canonicalized version and query against that. For example
I also found this good explanation from Stackoverflow, they mentioned that the only way to achieve your use-case is to store the field twice, please go through this link that explains how to achieve this.