Created
January 29, 2013 14:19
-
-
Save marcellobenigno/4664572 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- QUANDO OS DADOS ESTIVEREM EM COORDENADAS GEOGRÁFICAS, PARA REALIZAR A MEDIÇÃO DE DISTÂNCIAS E DE ÁREAS, | |
-- DEVE-SE UTILIZAR O COMANDO Geography(geom), EX. : | |
SELECT ST_Distance(Geography(a.geom), Geography(b.geom))/1000 as dist_km, | |
ST_Area(Geography(a.geom)) AS a1, ST_Area(Geography(b.geom)) AS b1 | |
FROM municipios_pb a, municipios_pb b | |
WHERE a.nome = 'Patos' AND b.nome = 'Campina Grande'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment