aboutsummaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorMunyoki Kilyungi2023-05-23 15:13:36 +0300
committerBonfaceKilz2023-05-26 08:40:22 +0300
commitdac9c38d9835a262b061fd351a13b19f67e82d5d (patch)
tree3c4d580afef415803ab9be44f6f408263f8a2e61 /examples
parent222019fa2f85f2d63f3fd733edbe691b8d37bf4d (diff)
downloadgn-transform-databases-dac9c38d9835a262b061fd351a13b19f67e82d5d.tar.gz
Sanitize a generif entry from GN
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/dump-generif.scm7
1 files changed, 4 insertions, 3 deletions
diff --git a/examples/dump-generif.scm b/examples/dump-generif.scm
index 415cb67..083490f 100755
--- a/examples/dump-generif.scm
+++ b/examples/dump-generif.scm
@@ -74,9 +74,10 @@
"")))
(multiset gn:geneWikiEntryOfGn
(let* ([entries
- (field
- ("GROUP_CONCAT(DISTINCT CONCAT_WS('::::', IFNULL(GeneCategory.Name, ''), IFNULL(GeneRIF.PubMed_ID, ''), GeneRIF.email, CAST(CONVERT(BINARY CONVERT(GeneRIF.comment USING latin1) USING utf8) AS VARCHAR(15000)), GeneRIF.createtime, IFNULL(weburl, '')) SEPARATOR';;;;;')"
- wikientry))]
+ (sanitize-rdf-string
+ (field
+ ("GROUP_CONCAT(DISTINCT CONCAT_WS('::::', IFNULL(GeneCategory.Name, ''), IFNULL(GeneRIF.PubMed_ID, ''), GeneRIF.email, CAST(CONVERT(BINARY CONVERT(GeneRIF.comment USING latin1) USING utf8) AS VARCHAR(15000)), GeneRIF.createtime, IFNULL(weburl, '')) SEPARATOR';;;;;')"
+ wikientry)))]
[comments (string-split-substring entries ";;;;;")])
(map
(match-lambda