|
43 | 43 | (j/execute! conn [(str "CREATE TABLE IF NOT EXISTS " table-name |
44 | 44 | "(id INT NOT NULL PRIMARY KEY, |
45 | 45 | balance INT NOT NULL)")]) |
| 46 | + (j/execute! conn [(str "SELECT LUA('return box.space." |
| 47 | + (clojure.string/upper-case table-name) |
| 48 | + ":alter{ is_sync = true } or 1')")]) |
46 | 49 | (doseq [a (:accounts test)] |
47 | 50 | (info "Populating account") |
48 | 51 | (sql/insert! conn table-name |
|
103 | 106 | "(id INT NOT NULL PRIMARY KEY," |
104 | 107 | "account_id INT NOT NULL," |
105 | 108 | "balance INT NOT NULL)")]) |
| 109 | + (j/execute! conn [(str "SELECT LUA('return box.space." |
| 110 | + (clojure.string/upper-case (str table-name a)) |
| 111 | + ":alter{ is_sync = true } or 1')")]) |
106 | 112 | (info "Populating account" a) |
107 | 113 | (sql/insert! conn (str table-name a) |
108 | 114 | {:id 0 |
|
174 | 180 | (j/execute! conn [(str "CREATE TABLE IF NOT EXISTS " table-name |
175 | 181 | "(id INT NOT NULL PRIMARY KEY, |
176 | 182 | balance INT NOT NULL)")]) |
| 183 | + (j/execute! conn [(str "SELECT LUA('return box.space." |
| 184 | + (clojure.string/upper-case table-name) |
| 185 | + ":alter{ is_sync = true } or 1')")]) |
177 | 186 | (doseq [a (:accounts test)] |
178 | 187 | (info "Populating account") |
179 | 188 | (sql/insert! conn table-name |
|
243 | 252 | (j/execute! conn [(str "CREATE TABLE IF NOT EXISTS " table-name a |
244 | 253 | "(id INT NOT NULL PRIMARY KEY," |
245 | 254 | "balance INT NOT NULL)")]) |
| 255 | + (j/execute! conn [(str "SELECT LUA('return box.space." |
| 256 | + (clojure.string/upper-case (str table-name a)) |
| 257 | + ":alter{ is_sync = true } or 1')")]) |
246 | 258 | (info "Populating account" a) |
247 | 259 | (sql/insert! conn (str table-name a) |
248 | 260 | {:id 0 |
|
0 commit comments