We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 13b6e39 commit 43dbf19Copy full SHA for 43dbf19
1 file changed
dialect_csvq.go
@@ -0,0 +1,22 @@
1
+// Copyright the DMorph contributors.
2
+// SPDX-License-Identifier: MPL-2.0
3
+
4
+package dmorph
5
6
+// DialectCSVQ returns a Dialect configured for CSVQ databases.
7
+func DialectCSVQ() BaseDialect {
8
+ return BaseDialect{
9
+ CreateTemplate: `
10
+ CREATE TABLE IF NOT EXISTS %s (
11
+ id,
12
+ create_ts
13
+ )`,
14
+ AppliedTemplate: `
15
+ SELECT id
16
+ FROM %s
17
+ ORDER BY create_ts ASC`,
18
+ RegisterTemplate: `
19
+ INSERT INTO %s (id)
20
+ VALUES(:id)`,
21
+ }
22
+}
0 commit comments