fix query order when using ttl and unique
This commit is contained in:
1 parent
ca0bd49565
commit
9fa5432a65
1 file changed
+1
-2
+1
-2
@@ -45,11 +45,10 @@ func (b *InsertBuilder) ToCql() (stmt string, names []string) {
|
||||
placeholders(&cql, len(b.columns))
|
||||
cql.WriteString(") ")
|
||||
|
||||
names = append(names, b.using.writeCql(&cql)...)
|
||||
|
||||
if b.unique {
|
||||
cql.WriteString("IF NOT EXISTS ")
|
||||
}
|
||||
names = append(names, b.using.writeCql(&cql)...)
|
||||
|
||||
stmt = cql.String()
|
||||
return
|
||||
|
||||
Reference in new issue
Block a user