mirror of
https://github.com/status-im/nim-sqlcipher.git
synced 2025-02-18 04:06:44 +00:00
Uncomment prepared statements execution
This commit is contained in:
parent
a306430824
commit
044c4a9021
@ -170,6 +170,7 @@ proc `$`*(dbVal: DbValue): string =
|
|||||||
of sqliteBlob: result.add "<blob>"
|
of sqliteBlob: result.add "<blob>"
|
||||||
of sqliteNull: result.add "nil"
|
of sqliteNull: result.add "nil"
|
||||||
result.add "]"
|
result.add "]"
|
||||||
|
]#
|
||||||
|
|
||||||
proc exec*(db: DbConn, sql: string, params: varargs[DbValue, toDbValue]) =
|
proc exec*(db: DbConn, sql: string, params: varargs[DbValue, toDbValue]) =
|
||||||
## Executes ``sql`` and raises SqliteError if not successful.
|
## Executes ``sql`` and raises SqliteError if not successful.
|
||||||
@ -178,6 +179,7 @@ proc exec*(db: DbConn, sql: string, params: varargs[DbValue, toDbValue]) =
|
|||||||
defer: prepared.finalize()
|
defer: prepared.finalize()
|
||||||
discard prepared.next
|
discard prepared.next
|
||||||
|
|
||||||
|
#[
|
||||||
# TODO: uncomment and test
|
# TODO: uncomment and test
|
||||||
proc execMany*(db: DbConn, sql: string, params: seq[seq[DbValue]]) =
|
proc execMany*(db: DbConn, sql: string, params: seq[seq[DbValue]]) =
|
||||||
## Executes ``sql`` repeatedly using each element of ``params`` as parameters.
|
## Executes ``sql`` repeatedly using each element of ``params`` as parameters.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user