fix exists() finisher
This commit is contained in:
parent
05c7f7d06a
commit
9c8262b702
1 changed files with 1 additions and 0 deletions
|
@ -105,6 +105,7 @@ func (q {{$tableNameSingular}}Query) Exists() (bool, error) {
|
||||||
var count int64
|
var count int64
|
||||||
|
|
||||||
queries.SetCount(q.Query)
|
queries.SetCount(q.Query)
|
||||||
|
queries.SetSelect(q.Query, []string{})
|
||||||
queries.SetLimit(q.Query, 1)
|
queries.SetLimit(q.Query, 1)
|
||||||
|
|
||||||
err := q.Query.QueryRow().Scan(&count)
|
err := q.Query.QueryRow().Scan(&count)
|
||||||
|
|
Loading…
Add table
Reference in a new issue