1
0
mirror of https://github.com/jbranchaud/til synced 2026-01-07 09:08:01 +00:00

Add Assumed Radius Of The Earth as a postgres til

This commit is contained in:
jbranchaud
2016-05-25 21:28:05 -05:00
parent 068651582a
commit 0c9602e9f3
2 changed files with 20 additions and 1 deletions

View File

@@ -0,0 +1,18 @@
# Assumed Radius Of The Earth
Using the
[`earthdistance`](https://www.postgresql.org/docs/8.3/static/earthdistance.html)
module, we can get the assumed radius of the earth (in meters).
```sql
> create extension cube;
CREATE EXTENSION
> create extension earthdistance;
CREATE EXTENSION
> select earth();
earth
---------
6378168
```