Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for $regex? #26

Open
Reggino opened this issue Sep 26, 2013 · 3 comments
Open

Support for $regex? #26

Reggino opened this issue Sep 26, 2013 · 3 comments

Comments

@Reggino
Copy link

Reggino commented Sep 26, 2013

Awesome project, thanks!

When writing a query using the syntax as mentioned here:
http://docs.mongodb.org/manual/reference/operator/regex/

query-engine throws an error. To be more specific: the query:

{ field: { $regex: 'acme.*corp', $options: 'i' } }

results in:

Error: Couldn't find the selector $regexp

@balupton
Copy link
Member

Hrmm, we don't support that syntax, but we do support regexes, just do {field: /acme.*corp/i} and you'll be good. If someone can mention this in our "differences from mongodb docs" that would be great.

@Reggino
Copy link
Author

Reggino commented Dec 19, 2013

The only thing is, the former syntax is much easier to serialize for e.g. AJAX requests... Consider a JavaScript browser-application, trying to query on the server, passing that query using AJAX. I think the standardized syntax offers an advantage here.

@dcolens
Copy link

dcolens commented Apr 17, 2014

Any plans to support $regex ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants