diff options
-rw-r--r-- | lib/impure/db_mysql.nim | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/impure/db_mysql.nim b/lib/impure/db_mysql.nim index 7c2901efd..197286f29 100644 --- a/lib/impure/db_mysql.nim +++ b/lib/impure/db_mysql.nim @@ -206,10 +206,7 @@ proc getValue*(db: DbConn, query: SqlQuery, ## executes the query and returns the first column of the first row of the ## result dataset. Returns "" if the dataset contains no rows or the database ## value is NULL. - result = "" - for row in fastRows(db, query, args): - result = row[0] - break + result = getRow(db, query, args)[0] proc tryInsertId*(db: DbConn, query: SqlQuery, args: varargs[string, `$`]): int64 {.tags: [FWriteDb].} = |