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

geo support for longitude/latitude ordering #2637

JerrySievert opened this issue Jun 24, 2015 · 3 comments


None yet
3 participants
Copy link

commented Jun 24, 2015

it's awesome that you are adding geo functionality to redis.

this is a request to follow the standard (EPSG:4326 aka WGS84), which uses longitude, latitude ordering.

this is the standard in the GIS world.



This comment has been minimized.

Copy link

commented Jun 24, 2015

+1 to this!

Also note that the ordering inside the GeoJSON response is [longitude, latitude] as well (assuming you're adding GeoJSON from the version). Since these values aren't named, a common source of errors and confusion is developers swapping the order of the two values. Sticking with the standard longitude,latitude ordering makes everything consistent that way.

I'm definitely excited to see this in Redis core!


This comment has been minimized.

Copy link

commented Jun 24, 2015

for more information about the geojson ordering (x,y,z), see:

antirez added a commit that referenced this issue Jun 26, 2015

Geo: from lat,lon API to lon,lat API according to GIS standard
The GIS standard and all the major DBs implementing GIS related
functions take coordinates as x,y that is longitude,latitude.
It was a bad start for Redis to do things differently, so even if this
means that existing users of the Geo module will be required to change
their code, Redis now conforms to the standard.

Usually Redis is very backward compatible, but this is not an exception
to this rule, since this is the first Geo implementation entering the
official Redis source code. It is not wise to try to be backward
compatible with code forks... :-)

Close #2637.

@antirez antirez closed this Jun 26, 2015


This comment has been minimized.

Copy link

commented Jun 26, 2015


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.