Created
August 9, 2017 15:35
-
-
Save timrobertson100/f31e4ad51c5ec5087ce5d93d01d555b2 to your computer and use it in GitHub Desktop.
Export of GBIF record counts by 1 degree cell, addressed on south-west of cell
This file contains hidden or 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
| CREATE TABLE tim.tom_export ROW FORMAT DELIMITED FIELDS TERMINATED BY ',' AS | |
| SELECT | |
| CAST(decimalLatitude AS INT) AS lat, | |
| CAST(decimalLongitude AS INT) AS lng, | |
| count(*) AS total | |
| FROM | |
| prod_a.occurrence_hdfs | |
| WHERE | |
| hasGeospatialIssues=0 AND decimalLatitude IS NOT NULL AND decimalLatitude IS NOT NULL | |
| GROUP BY | |
| CAST(decimalLatitude AS INT), | |
| CAST(decimalLongitude AS INT) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment