aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2019-07-30 20:50:38 -0700
committerBryan Newbold <bnewbold@robocracy.org>2019-07-30 20:50:38 -0700
commit0dbb6a1f02d9bce67af16339288128ce04b97eaf (patch)
tree220b2a1a8abc7cc2a20a456b015fc7a1a436dc5f
parentc47acaee8a339f358c5f39bcbc99ee1519811a93 (diff)
downloadchocula-0dbb6a1f02d9bce67af16339288128ce04b97eaf.tar.gz
chocula-0dbb6a1f02d9bce67af16339288128ce04b97eaf.zip
chocula: fix wikidata_qid inclusion
-rwxr-xr-xchocula.py2
-rw-r--r--chocula_schema.sql2
2 files changed, 3 insertions, 1 deletions
diff --git a/chocula.py b/chocula.py
index ad999f1..e54a017 100755
--- a/chocula.py
+++ b/chocula.py
@@ -1100,6 +1100,8 @@ class ChoculaDatabase():
if irow['slug'] in ('crossref',):
out['has_dois'] = True
# TODO: other DOI registrars (japan, datacite)
+ if irow['slug'] == 'wikidata':
+ out['wikidata_qid'] = irow['identifier']
for k in ('name',):
if not out.get(k) and irow[k]:
out[k] = irow[k]
diff --git a/chocula_schema.sql b/chocula_schema.sql
index 24adb5e..b3c7c2f 100644
--- a/chocula_schema.sql
+++ b/chocula_schema.sql
@@ -1,10 +1,10 @@
-
CREATE TABLE IF NOT EXISTS journal
(issnl TEXT NOT NULL PRIMARY KEY,
issne TEXT,
issnp TEXT,
fatcat_ident TEXT,
+ wikidata_qid TEXT,
name TEXT,
publisher TEXT,
country TEXT,