-
Notifications
You must be signed in to change notification settings - Fork 1k
Expand file tree
/
Copy pathquery.sql.go
More file actions
444 lines (370 loc) · 11 KB
/
query.sql.go
File metadata and controls
444 lines (370 loc) · 11 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
// Code generated by sqlc. DO NOT EDIT.
// versions:
// sqlc v1.30.0
// source: query.sql
package test
import (
"context"
"encoding/json"
"time"
)
const selectByCbinary = `-- name: SelectByCbinary :one
SELECT id FROM debug
WHERE Cbinary = ? LIMIT 1
`
func (q *Queries) SelectByCbinary(ctx context.Context, cbinary []byte) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCbinary, cbinary)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCbit = `-- name: SelectByCbit :one
SELECT id FROM debug
WHERE Cbit = ? LIMIT 1
`
func (q *Queries) SelectByCbit(ctx context.Context, cbit interface{}) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCbit, cbit)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCblob = `-- name: SelectByCblob :one
SELECT id FROM debug
WHERE Cblob = ? LIMIT 1
`
func (q *Queries) SelectByCblob(ctx context.Context, cblob []byte) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCblob, cblob)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCbool = `-- name: SelectByCbool :one
SELECT id FROM debug
WHERE Cbool = ? LIMIT 1
`
func (q *Queries) SelectByCbool(ctx context.Context, cbool bool) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCbool, cbool)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCchar = `-- name: SelectByCchar :one
SELECT id FROM debug
WHERE Cchar = ? LIMIT 1
`
func (q *Queries) SelectByCchar(ctx context.Context, cchar string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCchar, cchar)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCdate = `-- name: SelectByCdate :one
SELECT id FROM debug
WHERE Cdate = ? LIMIT 1
`
func (q *Queries) SelectByCdate(ctx context.Context, cdate time.Time) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCdate, cdate)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCdatetime = `-- name: SelectByCdatetime :one
SELECT id FROM debug
WHERE Cdatetime = ? LIMIT 1
`
func (q *Queries) SelectByCdatetime(ctx context.Context, cdatetime time.Time) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCdatetime, cdatetime)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCdec = `-- name: SelectByCdec :one
SELECT id FROM debug
WHERE Cdec = ? LIMIT 1
`
func (q *Queries) SelectByCdec(ctx context.Context, cdec string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCdec, cdec)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCdecimal = `-- name: SelectByCdecimal :one
SELECT id FROM debug
WHERE Cdecimal = ? LIMIT 1
`
func (q *Queries) SelectByCdecimal(ctx context.Context, cdecimal string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCdecimal, cdecimal)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCdouble = `-- name: SelectByCdouble :one
SELECT id FROM debug
WHERE Cdouble = ? LIMIT 1
`
func (q *Queries) SelectByCdouble(ctx context.Context, cdouble float64) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCdouble, cdouble)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCdoubleprecision = `-- name: SelectByCdoubleprecision :one
SELECT id FROM debug
WHERE Cdoubleprecision = ? LIMIT 1
`
func (q *Queries) SelectByCdoubleprecision(ctx context.Context, cdoubleprecision float64) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCdoubleprecision, cdoubleprecision)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCenum = `-- name: SelectByCenum :one
SELECT id FROM debug
WHERE Cenum = ? LIMIT 1
`
func (q *Queries) SelectByCenum(ctx context.Context, cenum NullDebugCenum) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCenum, cenum)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCfixed = `-- name: SelectByCfixed :one
SELECT id FROM debug
WHERE Cfixed = ? LIMIT 1
`
func (q *Queries) SelectByCfixed(ctx context.Context, cfixed string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCfixed, cfixed)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCfloat = `-- name: SelectByCfloat :one
SELECT id FROM debug
WHERE Cfloat = ? LIMIT 1
`
func (q *Queries) SelectByCfloat(ctx context.Context, cfloat float64) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCfloat, cfloat)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCint = `-- name: SelectByCint :one
SELECT id FROM debug
WHERE Cint = ? LIMIT 1
`
func (q *Queries) SelectByCint(ctx context.Context, cint int32) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCint, cint)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCinteger = `-- name: SelectByCinteger :one
SELECT id FROM debug
WHERE Cinteger = ? LIMIT 1
`
func (q *Queries) SelectByCinteger(ctx context.Context, cinteger int32) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCinteger, cinteger)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCjson = `-- name: SelectByCjson :one
SELECT id FROM debug
WHERE Cjson = ? LIMIT 1
`
func (q *Queries) SelectByCjson(ctx context.Context, cjson json.RawMessage) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCjson, cjson)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByClongblob = `-- name: SelectByClongblob :one
SELECT id FROM debug
WHERE Clongblob = ? LIMIT 1
`
func (q *Queries) SelectByClongblob(ctx context.Context, clongblob []byte) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByClongblob, clongblob)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByClongtext = `-- name: SelectByClongtext :one
SELECT id FROM debug
WHERE Clongtext = ? LIMIT 1
`
func (q *Queries) SelectByClongtext(ctx context.Context, clongtext string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByClongtext, clongtext)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCmediumblob = `-- name: SelectByCmediumblob :one
SELECT id FROM debug
WHERE Cmediumblob = ? LIMIT 1
`
func (q *Queries) SelectByCmediumblob(ctx context.Context, cmediumblob []byte) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCmediumblob, cmediumblob)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCmediumint = `-- name: SelectByCmediumint :one
SELECT id FROM debug
WHERE Cmediumint = ? LIMIT 1
`
func (q *Queries) SelectByCmediumint(ctx context.Context, cmediumint int32) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCmediumint, cmediumint)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCmediumtext = `-- name: SelectByCmediumtext :one
SELECT id FROM debug
WHERE Cmediumtext = ? LIMIT 1
`
func (q *Queries) SelectByCmediumtext(ctx context.Context, cmediumtext string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCmediumtext, cmediumtext)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCnumeric = `-- name: SelectByCnumeric :one
SELECT id FROM debug
WHERE Cnumeric = ? LIMIT 1
`
func (q *Queries) SelectByCnumeric(ctx context.Context, cnumeric string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCnumeric, cnumeric)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCreal = `-- name: SelectByCreal :one
SELECT id FROM debug
WHERE Creal = ? LIMIT 1
`
func (q *Queries) SelectByCreal(ctx context.Context, creal float64) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCreal, creal)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCset = `-- name: SelectByCset :one
SELECT id FROM debug
WHERE Cset = ? LIMIT 1
`
func (q *Queries) SelectByCset(ctx context.Context, cset DebugCset) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCset, cset)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCsmallint = `-- name: SelectByCsmallint :one
SELECT id FROM debug
WHERE Csmallint = ? LIMIT 1
`
func (q *Queries) SelectByCsmallint(ctx context.Context, csmallint int16) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCsmallint, csmallint)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCtext = `-- name: SelectByCtext :one
SELECT id FROM debug
WHERE Ctext = ? LIMIT 1
`
func (q *Queries) SelectByCtext(ctx context.Context, ctext string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCtext, ctext)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCtime = `-- name: SelectByCtime :one
SELECT id FROM debug
WHERE Ctime = ? LIMIT 1
`
func (q *Queries) SelectByCtime(ctx context.Context, ctime time.Time) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCtime, ctime)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCtimestamp = `-- name: SelectByCtimestamp :one
SELECT id FROM debug
WHERE Ctimestamp = ? LIMIT 1
`
func (q *Queries) SelectByCtimestamp(ctx context.Context, ctimestamp time.Time) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCtimestamp, ctimestamp)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCtinyblob = `-- name: SelectByCtinyblob :one
SELECT id FROM debug
WHERE Ctinyblob = ? LIMIT 1
`
func (q *Queries) SelectByCtinyblob(ctx context.Context, ctinyblob []byte) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCtinyblob, ctinyblob)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCtinyint = `-- name: SelectByCtinyint :one
SELECT id FROM debug
WHERE Ctinyint = ? LIMIT 1
`
func (q *Queries) SelectByCtinyint(ctx context.Context, ctinyint int8) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCtinyint, ctinyint)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCtinytext = `-- name: SelectByCtinytext :one
SELECT id FROM debug
WHERE Ctinytext = ? LIMIT 1
`
func (q *Queries) SelectByCtinytext(ctx context.Context, ctinytext string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCtinytext, ctinytext)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCvarbinary = `-- name: SelectByCvarbinary :one
SELECT id FROM debug
WHERE Cvarbinary = ? LIMIT 1
`
func (q *Queries) SelectByCvarbinary(ctx context.Context, cvarbinary []byte) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCvarbinary, cvarbinary)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCvarchar = `-- name: SelectByCvarchar :one
SELECT id FROM debug
WHERE Cvarchar = ? LIMIT 1
`
func (q *Queries) SelectByCvarchar(ctx context.Context, cvarchar string) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCvarchar, cvarchar)
var id int64
err := row.Scan(&id)
return id, err
}
const selectByCyear = `-- name: SelectByCyear :one
SELECT id FROM debug
WHERE Cyear = ? LIMIT 1
`
func (q *Queries) SelectByCyear(ctx context.Context, cyear int16) (int64, error) {
row := q.db.QueryRowContext(ctx, selectByCyear, cyear)
var id int64
err := row.Scan(&id)
return id, err
}
const selectById = `-- name: SelectById :one
SELECT id FROM debug
WHERE id = ? LIMIT 1
`
func (q *Queries) SelectById(ctx context.Context, id int64) (int64, error) {
row := q.db.QueryRowContext(ctx, selectById, id)
var id_2 int64
err := row.Scan(&id_2)
return id_2, err
}