DOI: 10.15468/dl.b5gv5x
title: Occurrence Download

description: A dataset containing 277912 records in GBIF matching the query:
SELECT
 kingdom,
 kingdomkey,
 phylum,
 phylumkey,
 class,
 classkey,
 "order",
 orderkey,
 family,
 familykey,
 genus,
 genuskey,
 species,
 specieskey,
 "year",
 IF(ISNULL(kingdomkey), NULL, SUM(COUNT(*)) OVER (
 PARTITION BY kingdomkey, "year")) kingdomcount,
 IF(ISNULL(phylumkey), NULL, SUM(COUNT(*)) OVER (
 PARTITION BY phylumkey, "year")) phylumcount,
 IF(ISNULL(classkey), NULL, SUM(COUNT(*)) OVER (
 PARTITION BY classkey, "year")) classcount,
 IF(ISNULL(orderkey), NULL, SUM(COUNT(*)) OVER (
 PARTITION BY orderkey, "year")) ordercount,
 IF(ISNULL(familykey), NULL, SUM(COUNT(*)) OVER (
 PARTITION BY familykey, "year")) familycount,
 IF(ISNULL(genuskey), NULL, SUM(COUNT(*)) OVER (
 PARTITION BY genuskey, "year")) genuscount,
 COUNT(*) occurrences,
 MIN(GBIF_TEMPORALUNCERTAINTY(eventdate, eventtime)) mintemporaluncertainty,
 MIN(COALESCE(coordinateuncertaintyinmeters, 1000)) mincoordinateuncertaintyinmeters
FROM
 occurrence
WHERE
 (occurrence.level0gid IN ('BGD.2_1', 'BTN', 'NPL', 'AFG.1_1', 'AFG.2_1', 'AFG.3_1', 'AFG.4_1', 'AFG.8_1', 'AFG.9_1', 'AFG.14_1', 'AFG.16_1', 'AFG.17_1', 'AFG.20_1', 'AFG.21_1', 'AFG.24_1', 'AFG.25_1', 'AFG.28_1', 'AFG.29_1', 'AFG.31_1', 'IRN.26.6_1', 'BGD.2.1_1', 'BGD.2.8_1', 'BGD.2.11_1', 'CHN.30.10_1', 'CHN.18.4_1', 'CHN.23.6.4_1', 'CHN.11.9.3_1', 'CHN.5.13_1', 'CHN.5.14_1', 'CHN.21.1_1', 'CHN.21.3_1', 'CHN.21.2_1', 'CHN.21.5_1', 'CHN.21.6_1', 'CHN.21.7_1', 'CHN.26.16_1', 'CHN.26.5_1', 'CHN.30.5_1', 'CHN.5.3_1', 'CHN.26.9.10_1', 'CHN.5.13.3_1', 'IND.4_1', 'IND.35_1', 'IND.13_1', 'IND.21_1', 'Z01', 'IND.22_1', 'IND.23_1', 'IND.24_1', 'IND.30_1', 'IND.33_1', 'Z07', 'IND.36.6_1', 'MMR.3_1', 'MMR.13_1', 'MMR.11_1', 'MMR.4_1', 'PAK.5_1', 'PAK.3_1', 'PAK.2.6.5_1', 'PAK.2.5_1', 'PAK.2.4.4_1', 'PAK.2.4.2_1', 'PAK.2.2.3_1', 'PAK.2.3.4_1', 'PAK.2.6.3_1', 'PAK.2.1.8_1', 'PAK.2.6.4_1', 'PAK.2.5.4_1', 'PAK.2.6.2_1', 'PAK.2.1.6_1', 'PAK.2.1.5_1', 'PAK.2.2.2_1', 'PAK.2.1.4_1', 'PAK.2.5.1_1', 'PAK.2.4.1_1', 'PAK.2.3.1_1', 'PAK.2.4.3_1', 'PAK.2.1.1_1', 'PAK.2.6.1_1') OR occurrence.level1gid IN ('BGD.2_1', 'BTN', 'NPL', 'AFG.1_1', 'AFG.2_1', 'AFG.3_1', 'AFG.4_1', 'AFG.8_1', 'AFG.9_1', 'AFG.14_1', 'AFG.16_1', 'AFG.17_1', 'AFG.20_1', 'AFG.21_1', 'AFG.24_1', 'AFG.25_1', 'AFG.28_1', 'AFG.29_1', 'AFG.31_1', 'IRN.26.6_1', 'BGD.2.1_1', 'BGD.2.8_1', 'BGD.2.11_1', 'CHN.30.10_1', 'CHN.18.4_1', 'CHN.23.6.4_1', 'CHN.11.9.3_1', 'CHN.5.13_1', 'CHN.5.14_1', 'CHN.21.1_1', 'CHN.21.3_1', 'CHN.21.2_1', 'CHN.21.5_1', 'CHN.21.6_1', 'CHN.21.7_1', 'CHN.26.16_1', 'CHN.26.5_1', 'CHN.30.5_1', 'CHN.5.3_1', 'CHN.26.9.10_1', 'CHN.5.13.3_1', 'IND.4_1', 'IND.35_1', 'IND.13_1', 'IND.21_1', 'Z01', 'IND.22_1', 'IND.23_1', 'IND.24_1', 'IND.30_1', 'IND.33_1', 'Z07', 'IND.36.6_1', 'MMR.3_1', 'MMR.13_1', 'MMR.11_1', 'MMR.4_1', 'PAK.5_1', 'PAK.3_1', 'PAK.2.6.5_1', 'PAK.2.5_1', 'PAK.2.4.4_1', 'PAK.2.4.2_1', 'PAK.2.2.3_1', 'PAK.2.3.4_1', 'PAK.2.6.3_1', 'PAK.2.1.8_1', 'PAK.2.6.4_1', 'PAK.2.5.4_1', 'PAK.2.6.2_1', 'PAK.2.1.6_1', 'PAK.2.1.5_1', 'PAK.2.2.2_1', 'PAK.2.1.4_1', 'PAK.2.5.1_1', 'PAK.2.4.1_1', 'PAK.2.3.1_1', 'PAK.2.4.3_1', 'PAK.2.1.1_1', 'PAK.2.6.1_1') OR occurrence.level2gid IN ('BGD.2_1', 'BTN', 'NPL', 'AFG.1_1', 'AFG.2_1', 'AFG.3_1', 'AFG.4_1', 'AFG.8_1', 'AFG.9_1', 'AFG.14_1', 'AFG.16_1', 'AFG.17_1', 'AFG.20_1', 'AFG.21_1', 'AFG.24_1', 'AFG.25_1', 'AFG.28_1', 'AFG.29_1', 'AFG.31_1', 'IRN.26.6_1', 'BGD.2.1_1', 'BGD.2.8_1', 'BGD.2.11_1', 'CHN.30.10_1', 'CHN.18.4_1', 'CHN.23.6.4_1', 'CHN.11.9.3_1', 'CHN.5.13_1', 'CHN.5.14_1', 'CHN.21.1_1', 'CHN.21.3_1', 'CHN.21.2_1', 'CHN.21.5_1', 'CHN.21.6_1', 'CHN.21.7_1', 'CHN.26.16_1', 'CHN.26.5_1', 'CHN.30.5_1', 'CHN.5.3_1', 'CHN.26.9.10_1', 'CHN.5.13.3_1', 'IND.4_1', 'IND.35_1', 'IND.13_1', 'IND.21_1', 'Z01', 'IND.22_1', 'IND.23_1', 'IND.24_1', 'IND.30_1', 'IND.33_1', 'Z07', 'IND.36.6_1', 'MMR.3_1', 'MMR.13_1', 'MMR.11_1', 'MMR.4_1', 'PAK.5_1', 'PAK.3_1', 'PAK.2.6.5_1', 'PAK.2.5_1', 'PAK.2.4.4_1', 'PAK.2.4.2_1', 'PAK.2.2.3_1', 'PAK.2.3.4_1', 'PAK.2.6.3_1', 'PAK.2.1.8_1', 'PAK.2.6.4_1', 'PAK.2.5.4_1', 'PAK.2.6.2_1', 'PAK.2.1.6_1', 'PAK.2.1.5_1', 'PAK.2.2.2_1', 'PAK.2.1.4_1', 'PAK.2.5.1_1', 'PAK.2.4.1_1', 'PAK.2.3.1_1', 'PAK.2.4.3_1', 'PAK.2.1.1_1', 'PAK.2.6.1_1') OR occurrence.level3gid IN ('BGD.2_1', 'BTN', 'NPL', 'AFG.1_1', 'AFG.2_1', 'AFG.3_1', 'AFG.4_1', 'AFG.8_1', 'AFG.9_1', 'AFG.14_1', 'AFG.16_1', 'AFG.17_1', 'AFG.20_1', 'AFG.21_1', 'AFG.24_1', 'AFG.25_1', 'AFG.28_1', 'AFG.29_1', 'AFG.31_1', 'IRN.26.6_1', 'BGD.2.1_1', 'BGD.2.8_1', 'BGD.2.11_1', 'CHN.30.10_1', 'CHN.18.4_1', 'CHN.23.6.4_1', 'CHN.11.9.3_1', 'CHN.5.13_1', 'CHN.5.14_1', 'CHN.21.1_1', 'CHN.21.3_1', 'CHN.21.2_1', 'CHN.21.5_1', 'CHN.21.6_1', 'CHN.21.7_1', 'CHN.26.16_1', 'CHN.26.5_1', 'CHN.30.5_1', 'CHN.5.3_1', 'CHN.26.9.10_1', 'CHN.5.13.3_1', 'IND.4_1', 'IND.35_1', 'IND.13_1', 'IND.21_1', 'Z01', 'IND.22_1', 'IND.23_1', 'IND.24_1', 'IND.30_1', 'IND.33_1', 'Z07', 'IND.36.6_1', 'MMR.3_1', 'MMR.13_1', 'MMR.11_1', 'MMR.4_1', 'PAK.5_1', 'PAK.3_1', 'PAK.2.6.5_1', 'PAK.2.5_1', 'PAK.2.4.4_1', 'PAK.2.4.2_1', 'PAK.2.2.3_1', 'PAK.2.3.4_1', 'PAK.2.6.3_1', 'PAK.2.1.8_1', 'PAK.2.6.4_1', 'PAK.2.5.4_1', 'PAK.2.6.2_1', 'PAK.2.1.6_1', 'PAK.2.1.5_1', 'PAK.2.2.2_1', 'PAK.2.1.4_1', 'PAK.2.5.1_1', 'PAK.2.4.1_1', 'PAK.2.3.1_1', 'PAK.2.4.3_1', 'PAK.2.1.1_1', 'PAK.2.6.1_1'))
 AND occurrence.hascoordinate = TRUE
 AND occurrence.hasgeospatialissues = FALSE
 AND occurrence.occurrencestatus = 'PRESENT'
 AND NOT GBIF_STRINGARRAYCONTAINS(occurrence.issue, 'TAXON_MATCH_FUZZY', TRUE)
 AND (occurrence.distancefromcentroidinmeters &gt;= 2000.0 OR occurrence.distancefromcentroidinmeters IS NULL)
 AND NOT occurrence.basisofrecord IN ('FOSSIL_SPECIMEN', 'LIVING_SPECIMEN')
 AND (occurrence.specieskey IS NOT NULL AND occurrence."year" IS NOT NULL)
GROUP BY
 occurrence.kingdom,
 occurrence.kingdomkey,
 occurrence.phylum,
 occurrence.phylumkey,
 occurrence.class,
 occurrence.classkey,
 occurrence."order",
 occurrence.orderkey,
 occurrence.family,
 occurrence.familykey,
 occurrence.genus,
 occurrence.genuskey,
 occurrence.species,
 occurrence.specieskey,
 occurrence."year"

 The dataset's 277912 records were derived from 1141 constituent datasets; see https://api.gbif.org/v1/occurrence/download/0000158-250415084134356/datasets/export for details.
 
Data from some individual datasets included in this download may be licensed under less restrictive terms.