aboutsummaryrefslogtreecommitdiff
path: root/dump
AgeCommit message (Collapse)Author
2023-05-26Replace broken char-sets with an empty stringMunyoki Kilyungi
* dump/strings.scm (sanitize-rdf-string): Add extra elements---broken chars---to replace with "". Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-05-26Re-organize dumping macros and associated functionsMunyoki Kilyungi
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-05-26Always use "~a" to output like "display"Munyoki Kilyungi
Replacing "~s" with "~a" will print utf-8 characters correctly. Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-05-26Return an empty string if args passed to ontology is emptyMunyoki Kilyungi
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-05-26Fix how a symbol is displayed in the final RDFMunyoki Kilyungi
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Simplify pattern matching when checking for a nodeMunyoki Kilyungi
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Use match syntax to print object correctly during dumpMunyoki Kilyungi
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Allow running raw queries in field formMunyoki Kilyungi
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Annotate fields with a custom scheme such as "^^xsd:datetime"Munyoki Kilyungi
* dump.scm (annotate-field): New function. * dump/triples.scm (triple): Print a string as they appear with DISPLAY should they contain "\"" thus enabling a triple that looks like: gn:species_mus_musculus gn:name "Mouse"^^xsd:string Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Add a method to transform epoch time to a human readable formatMunyoki Kilyungi
* dump/utils.scm: Import srfi-19. Export time-unix->string. (time-unix->string): New function. Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Create a method to define ontologies as symbolsMunyoki Kilyungi
* dump/triples.scm: Export ontology. (ontology): New function. Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2023-04-05Add ability to have operations such as GROUP_CONCAT in SELECT clauseMunyoki Kilyungi
This change enables having: "... GROUP_CONCAT(GeneRIF_BASIC.PubMedId) AS alias ..." as part of the query. * dump.scm (field->key, field->assoc-ref): Add new syntax-rule. * dump/sql.scm (select-query): Ditto. Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
2022-10-30Move triple utilities to new module.Arun Isaac
* dump.scm (string->identifier, string-blank?, triple, prefix): Move to ... * dump/triples.scm: ... new file. * dump.scm: Import (dump triples).
2022-10-30Move string-blank? to (dump utils).Arun Isaac
* dump.scm (string-blank?): Move to ... * dump/utils.scm (string-blank?): ... here.
2022-03-10Rename the delete verb of map-alist to remove.Arun Isaac
The delete verb of map-alist somehow interacts with the delete function from (srfi srfi-1), and I'm not able to figure out how. It is simpler to just rename the delete verb to remove. * dump/utils.scm: Do not rename the delete function from (srfi srfi-1). (map-alist): Rename the delete verb to remove. * tests.scm ("map-alist docstring example"): Update test.
2021-12-23Add dumped? field to <column> type.Arun Isaac
* dump/table.scm (<column>): Add dumped? field. Rename constructor to column-constructor. (make-column): Implement as wrapper around column-constructor.
2021-12-20Capture full column type.Arun Isaac
Capture full column type instead of just whether it is an integer. * dump.scm (dump-data-table): Capture full column type in <column> object. * dump/table.scm (<column>)[int?]: Delete member. [type]: New member. Export column-type instead of column-int?.
2021-12-20Move <table> and <column> types to separate module.Arun Isaac
* dump.scm (<table>, <column>): Move to ... * dump/table.scm: ... here.
2021-12-16Specify map-alist behaviour for multiple set verbs.Arun Isaac
* dump/utils.scm (map-alist): Specify behaviour for multiple set verbs.
2021-12-16Generalize collect-keys and key->assoc-ref.Arun Isaac
The generalized versions---collect forms and translate-forms---will be required by other macros. * dump/utils.scm (collect-forms, translate forms): New public functions. (collect-keys): Rewrite in terms of collect-forms. (key->assoc-ref): Rewrite in terms of translate-forms.
2021-12-16Rename away delete from (srfi srfi-1).Arun Isaac
delete from (srfi srfi-1) somehow interferes with the delete verb of map-alist. It is not clear why. * dump/utils.scm (dump): Rename delete to srfi:delete while importing.
2021-12-15Move string similarity functions to separate module.Arun Isaac
* dump.scm: Use (dump string-similarity). (trigrams, jaccard-index, jaccard-string-similarity, jaccard-string-similar?): Move to ... * dump/string-similarity.scm: ... here.
2021-12-11Implement S-expression like SQL select query.Arun Isaac
* dump/sql.scm: Import (srfi srfi-1). Export select-query. (select-query): New macro.
2021-12-04Implement the map-alist DSL.Arun Isaac
map-alist is a DSL to transform one association list into another. These transformations are frequently required when dumping tables, especially metadata tables. * dump/utils.scm: New file.
2021-08-27Initial commitArun Isaac