X-Git-Url: http://git.kpe.io/?p=clsql.git;a=blobdiff_plain;f=db-sqlite%2Fsqlite-sql.lisp;h=a2bc7cdfcac4cf09ef51285671cc790a0817da4f;hp=0b9994589491b9046cd10104bcec464a254c52ff;hb=fe6d36c16c61c855fc3b0c0c7c07f3cf3de4241d;hpb=d01eae29d96b37219607a12fa21f49ec3a2b4a47 diff --git a/db-sqlite/sqlite-sql.lisp b/db-sqlite/sqlite-sql.lisp index 0b99945..a2bc7cd 100644 --- a/db-sqlite/sqlite-sql.lisp +++ b/db-sqlite/sqlite-sql.lisp @@ -97,7 +97,7 @@ (when (> n-col 0) (when field-names (setf col-names (loop for i from 0 below n-col - collect (sqlite:sqlite-aref sqlite-col-names i)))) + collect (sqlite:sqlite-aref sqlite-col-names i (encoding database))))) (let ((canonicalized-result-types (canonicalize-result-types result-types n-col sqlite-col-names))) (flet ((extract-row-data (row) @@ -105,7 +105,8 @@ (loop for i from 0 below n-col collect (clsql-uffi:convert-raw-field (sqlite:sqlite-raw-aref row i) - canonicalized-result-types i)))) + (nth i canonicalized-result-types) + :encoding (encoding database))))) (push (extract-row-data new-row) rows) ;; Read subsequent rows. @@ -224,8 +225,8 @@ do (setf (car rest) (clsql-uffi:convert-raw-field (sqlite:sqlite-raw-aref row i) - result-types - i))) + (nth i result-types) + :encoding (encoding database)))) (sqlite:sqlite-free-row row) t))))