Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
equalsIgnoreCase doesn't work with MongoDB #85
I've recently discovered that using the equalsIgnoreCase operation on a String property doesn't yield the desired result.
An example: I have two user acccounts "Rodney" and "Silvia". Even if I search for a part of one of the account's names, I get the account in the result set. So, code like this:
yields "Rodney" as result, but it shouldn't. I suspect you have implemented this using $regex with the i option. In this case you don't have to use "R" as search string, but rather "^R$".