-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add table creation script obtainig for h2 databases
- Loading branch information
Showing
1 changed file
with
7 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
;;; structure.clj -- Receive database stucture and keep it in cache. | ||
|
||
;;; Copyright © 2016-2023 - Kostafey <[email protected]> | ||
;;; Copyright © 2016-2024 - Kostafey <[email protected]> | ||
|
||
;;; This program is free software; you can redistribute it and/or modify | ||
;;; it under the terms of the GNU General Public License as published by | ||
|
@@ -366,6 +366,12 @@ | |
FROM information_schema.tables AS t | ||
WHERE UPPER(t.table_name) = '%s' " | ||
(s/upper-case entity-name))) | ||
:table (fn [& {:keys [entity-name]}] | ||
(format " | ||
SELECT sql | ||
FROM INFORMATION_SCHEMA.TABLES | ||
WHERE TABLE_NAME = '%s' " | ||
(s/upper-case entity-name))) | ||
:view (fn [& {:keys [entity-name]}] | ||
((default-queries :view) :entity-name entity-name))} | ||
;;-------- | ||
|