Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion JSON Serialization and Near Query Distance Maximum Distance Limit
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Andrew Brown  
View profile  
 More options Apr 9 2011, 12:49 am
From: Andrew Brown <uscfan1...@gmail.com>
Date: Fri, 8 Apr 2011 21:49:39 -0700 (PDT)
Local: Sat, Apr 9 2011 12:49 am
Subject: JSON Serialization and Near Query Distance Maximum Distance Limit
I apologize if this is a duplicate post. I tried to email this group
earlier today, but I think it failed because I wasn't a member yet.

Anyway, I have to questions about mongoengine. First, I'm using
mongoengine with django and I'm trying to return the results of some
queries in JSON format. Is there a standard way for serializing
mongoengine QuerySets as JSON? I found this post on the topic from
over a year ago, but I want to check and see if it is still the best
way. http://groups.google.com/group/mongoengine-dev/browse_thread/thread/d...

Second, does mongoengine support specifying a maximum distance for
"near" queries? For example I want to do this query:

Place.objects(location__near=[lat, lng]).limit(20)

 but I only want results within 1 degree of the specified location,
even if that is less than the limit of 20.

If that's not built in to mongoengine I'll just use the __raw__
option, but figured I would check first.

Thanks,
Andrew


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.