Skip to content

Add 'withinPolygon' to ParseQuery #3290

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

Closed
tarekskr opened this issue Dec 28, 2016 · 8 comments
Closed

Add 'withinPolygon' to ParseQuery #3290

tarekskr opened this issue Dec 28, 2016 · 8 comments
Labels
type:feature New feature or improvement of existing feature

Comments

@tarekskr
Copy link

In addition to the existing 'ParseQuery.withinGeoBox', we also need a 'withinPolygon' function so that we could search inside a polygon of GeoPoints.

AFAIK, this is supported by MongoDB, but I have no idea how to implement it myself in Parse :)

Here is the MongoDB documentation: https://docs.mongodb.com/manual/reference/operator/query/polygon/#op._S_polygon

@madsb
Copy link
Contributor

madsb commented Dec 28, 2016

I am also in need of this feature. Unfortunately AFAIK, previous pull requests have been denied citing the need to be compatible with the Parse.com legacy database, which runs an older, non-geojson compatible version of MongoDB.

@natanrolnik
Copy link
Contributor

I believe this is actually a good feature to have.

Recently, the Parse Server Evolution repo was created to manage better feature requests.

@tarekskr do you think you can add a PR there with the proposal? Fork the repo, add a new proposal according to this template to the proposals folder, and create the PR.

@tarekskr
Copy link
Author

@natanrolnik I am not that familiar with github, but if you guys could do it please feel free to copy the request and make it your own. Many thanks!

@madsb
Copy link
Contributor

madsb commented Jan 21, 2017

Alright, I've created a pull request with the feature request. Please let me know if I missed something.

@hramos hramos changed the title [Feature Request] Add 'withinPolygon' to ParseQuery Add 'withinPolygon' to ParseQuery Feb 9, 2017
@otymartin
Copy link

Hey @madsb does this add support for geoJSON/2dsphere location queries? That would be a quantum leap for location based applications

@madsb
Copy link
Contributor

madsb commented Apr 10, 2017

@otymartin At the moment it's just a feature request, but I agree completely! Hopefully someone with the right coding chops will take a stab at it. Well, at least as soon as the pull request is merged (hint-hint, @flovilmart ;) ).

@otymartin
Copy link

@madsb
Question & maybe is just my lack of knowledge on the subject but shouldnt it still be technically possible to associate PFObjects with a geoJSON property and use cloud code to perform 2dsphere queries. As I understand these are capabilities existing with mongoDB independent of parse server or does parse-server/parse-iOS SDK need to add some kind of support for it?

@dplewis
Copy link
Member

dplewis commented Nov 15, 2017

Added in Parse Server 2.5.0. Closes via #3866

@dplewis dplewis closed this as completed Nov 15, 2017
@mtrezza mtrezza added type:feature New feature or improvement of existing feature and removed type:improvement labels Dec 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:feature New feature or improvement of existing feature
Projects
None yet
Development

No branches or pull requests

7 participants