Saturday, February 16, 2013

Re: Need help with GeoDjango distance query.

On Fri, Feb 15, 2013 at 10:00 PM, mack the finger <nbvfour@gmail.com> wrote:
> http://stackoverflow.com/questions/14889780/distance-query-within-a-certain-distance-based-on-value-in-joined-table
>
> Basically I want all objects within a certain distance, AS WELL as within
> each object's preferred distance.
>

just off the bat -- the distance query expects a decimal.Decimal
object - so you'd need to convert whatever
models.F('connection_distance') returns into a valid Decimal before
passing it to the query ..

-Sanjay

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate