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
SELECT | |
SUM(CASE WHEN requestpath LIKE '/v1/species/match%' THEN 1 ELSE 0 END) AS match, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/vernacularNames' THEN 1 ELSE 0 END) AS vernacularNames, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/verbatim' THEN 1 ELSE 0 END) AS verbatim, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/typeSpecimens' THEN 1 ELSE 0 END) AS typeSpecimens, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/toc' THEN 1 ELSE 0 END) AS toc_count, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/synonyms' THEN 1 ELSE 0 END) AS synonyms_count, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/speciesProfiles' THEN 1 ELSE 0 END) AS speciesProfiles, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/related' THEN 1 ELSE 0 END) AS related, | |
SUM(CASE WHEN requestpath LIKE '/v1/species/%/references' THEN 1 ELSE 0 END) AS species_references, |
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
update species_list set is_private=true WHERE list_name REGEXP '^[0-9]' and list_type='OTHER' and is_authoritative is null; | |
update species_list set is_private=true WHERE list_name REGEXP '^[0-9]' and list_type='SPATIAL_PORTAL' and is_authoritative is null; | |
update species_list set is_private=true WHERE list_name like 'My species list%' and list_type='OTHER' and is_authoritative is null; | |
update species_list set is_private=true WHERE list_name = 'My species list' and list_type='SPATIAL_PORTAL' and is_authoritative is null; | |
update species_list set is_private=true WHERE list_name like 'My species list%' and list_type='SPATIAL_PORTAL' and is_authoritative is null; | |
update species_list set is_private=true WHERE list_name = 'My species list' and is_authoritative is null; | |
update species_list set is_private=true | |
WHERE | |
( list_name like 'My species list%' | |
OR list_name = 'My species list' |
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
_class | |
abcdIdentificationQualifier | |
abcdIdentificationQualifierInsertionPoint | |
abcdTypeStatus | |
acceptedNameUsage | |
associatedMedia | |
associatedOccurrences | |
associatedReferences | |
associatedSequences | |
associatedTaxa |
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
_class | |
_qa | |
abcdIdentificationQualifier | |
abcdIdentificationQualifier_p | |
abcdIdentificationQualifierInsertionPoint | |
abcdTypeStatus | |
acceptedNameUsage | |
associatedMedia | |
associatedOccurrences | |
associatedOccurrences_p |
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
import groovy.json.JsonSlurper | |
statusUrl = new URL("http://XXXXXXXX:8983/solr/admin/collections?action=clusterstatus&wt=json") | |
slurper = new JsonSlurper() | |
json = slurper.parseText(statusUrl.text) | |
collectionName = "biocache" | |
println("Parsing") |
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
package au.org.ala.biocache.tool | |
import au.org.ala.biocache.Config | |
import org.slf4j.LoggerFactory | |
object FixDatePrecision extends au.org.ala.biocache.cmd.Tool { | |
def cmd = "fix-date-precision" | |
def desc = "Cleanup old date precision values." |
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
2017-09-20 02:07:07,477 INFO [GbifRegistryService] Updating GBIF organisation dp46: 8dda5e56-c4b4-4af2-90f9-170d9d22f2c1 | |
2017-09-20 02:07:08,179 INFO [GbifRegistryService] Setting GBIF country of attribution to AU | |
2017-09-20 02:07:09,030 INFO [GbifRegistryService] Successfully updated provider in GBIF: 8dda5e56-c4b4-4af2-90f9-170d9d22f2c1 | |
2017-09-20 02:07:09,839 INFO [GbifRegistryService] Removing contacts | |
2017-09-20 02:07:10,670 INFO [GbifRegistryService] Removed contact 615477 | |
2017-09-20 02:07:10,671 INFO [GbifRegistryService] Successfully synced contacts: 8dda5e56-c4b4-4af2-90f9-170d9d22f2c1 | |
2017-09-20 02:07:10,674 INFO [GbifRegistryService] Creating GBIF resource for dr797 | |
2017-09-20 02:07:10,674 INFO [GbifRegistryService] Creating dataset in GBIF: null | |
2017-09-20 02:07:10,674 WARN [GbifRegistryService] Unable to register dataset - please check license: dr797 : Whicher Scarp Flora Survey : other | |
2017-09-20 02:07:10,674 INFO [GbifRegistryService] Registry key not set for resource: dr797. Not sy |
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 nvc_scotland (pid integer, name varchar(255), the_geom geometry, the_geom_4326 geometry); | |
insert into nvc_scotland(pid, name, the_geom) | |
SELECT nextval('objects_id_seq'::regclass), commun_cat, ST_UNION(the_geom) FROM "65" where commun_cat='A, Aquatic Communities' GROUP BY commun_cat; | |
insert into nvc_scotland(pid, name, the_geom) | |
SELECT nextval('objects_id_seq'::regclass), commun_cat, ST_UNION(the_geom) FROM "65" where commun_cat='W, Woodlands' GROUP BY commun_cat; | |
# Doesnt return..... | |
insert into nvc_scotland(pid, name, the_geom) |
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
delete from "65" where COMMUN_CAT IS NULL; | |
update "65" set COMMUN_CAT = 'A, Aquatic Communities' where COMMUN_CAT='A'; | |
update "65" set COMMUN_CAT = 'CG, Calciolous Grassland' where COMMUN_CAT='CG'; | |
update "65" set COMMUN_CAT = 'H, Heathland' where COMMUN_CAT='H'; | |
update "65" set COMMUN_CAT = 'M, Mires' where COMMUN_CAT='M'; | |
update "65" set COMMUN_CAT = 'MC, Maritime Cliff Communities' where COMMUN_CAT='MC'; | |
update "65" set COMMUN_CAT = 'MG, Mesotrophic Grassland' where COMMUN_CAT='MG'; | |
update "65" set COMMUN_CAT = 'N/A, Non-standard code' where COMMUN_CAT='N/A'; | |
update "65" set COMMUN_CAT = 'S, Swamps and tall-herb fens' where COMMUN_CAT='S'; | |
update "65" set COMMUN_CAT = 'OW, Open Water' where COMMUN_CAT='OW'; |
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
[ | |
{ | |
"speciesGroup": "Mammals", | |
"taxonRank": "order", | |
"taxa": [ | |
{ | |
"name": "DASYUROMORPHIA", | |
"common": "Carnivorous Marsupials" | |
}, | |
{ |
NewerOlder