diff options
author | Munyoki Kilyungi | 2023-07-03 18:48:46 +0300 |
---|---|---|
committer | Munyoki Kilyungi | 2023-07-21 14:36:36 +0300 |
commit | ff7a8c5419f464fbcdd2fece84df306025f05cf1 (patch) | |
tree | b34fd0c7bab7250f71333f360fb0c2471aaed035 | |
parent | 976091d5130d6c2641efb2a123fe10b600b452a7 (diff) | |
download | gn-transform-databases-ff7a8c5419f464fbcdd2fece84df306025f05cf1.tar.gz |
Make dumping optional, defaulting to #t
There may be a case where one just wants to dump metadata about the
s-exps only.
-rw-r--r-- | dump/special-forms.scm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/dump/special-forms.scm b/dump/special-forms.scm index ded0db5..2b6a0bb 100644 --- a/dump/special-forms.scm +++ b/dump/special-forms.scm @@ -462,4 +462,13 @@ must be remedied." ((field table column alias) alias)) x)))) #'(predicate-clauses ...))))) + (when (dump-configuration-table-dump? configuration) + (sql-for-each (lambda (row) + (scm->triples + (map-alist row #,@(field->key #'(predicate-clauses ...))) + #,(field->assoc-ref #'row #'subject))) + db + (select-query #,(collect-fields #'(subject predicate-clauses ...)) + (primary-table other-tables ...) + tables-raw ...)))))) (_ (error "Invalid define-dump syntax:" (syntax->datum x)))))) |