diff options
author | Munyoki Kilyungi | 2023-07-03 18:48:46 +0300 |
---|---|---|
committer | BonfaceKilz | 2023-07-30 12:29:56 +0300 |
commit | 909eb42f9cf08cc7c88bca2fc25f3281f9787190 (patch) | |
tree | b34fd0c7bab7250f71333f360fb0c2471aaed035 | |
parent | ed440ac1c18058da9a0b7fa2cb62834f20f5d1ee (diff) | |
download | gn-transform-databases-909eb42f9cf08cc7c88bca2fc25f3281f9787190.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)))))) |