Thursday, January 3, 2019

Re: Are distance lookups available for MySQL or not?


Em qui, 3 de jan de 2019 às 10:38, Clara Daia <claradaiahd@gmail.com> escreveu:
Hello, Jason

I appreciate your help, and I tried running the test with a MySQL container but got the same error.
The MySQL spatial reference does not have a'dwithin' entry or similar either.

I changed my query to
self.assertEqual(MyModel.objects.filter(
geopositionfield__distance_lt=(
Point(-25.427855, -49.279644),
0.00028321143293561684)
).count(), 1)
And it seems to have worked, both on the MySQL and the MariaDB containers.
I suppose there is limited support and the documentation should specify which distance functions are available for MySQL. Do you think I should file a ticket?

Best regards,

Clara

--
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 https://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAMpbhxy0E%3DnRanAd%2Bi%2BBXkfr%3DRGJ3h72dp1BcBbJZpXbD_SQMQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment