X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=db-odbc%2Fodbc-sql.lisp;h=70e14787c387bc09e0842371b420dc35dd73cf4e;hb=3a18cef462f8fb90652450128cd3dff5f7feaf7f;hp=b43a3226a6168d628d1faf43a5752eaa25ad17d1;hpb=f716bb1161cf9e89a96945c4a444244f9d303691;p=clsql.git diff --git a/db-odbc/odbc-sql.lisp b/db-odbc/odbc-sql.lisp index b43a322..70e1478 100644 --- a/db-odbc/odbc-sql.lisp +++ b/db-odbc/odbc-sql.lisp @@ -17,7 +17,7 @@ ;;;; ************************************************************************* (defpackage #:clsql-odbc - (:use #:common-lisp #:clsql-base-sys) + (:use #:common-lisp #:clsql-base) (:export #:odbc-database) (:documentation "This is the CLSQL interface to ODBC.")) @@ -256,10 +256,14 @@ ;; NULLABLE is the eleventh column (loop for row in rows when (string-equal attribute (fourth row)) - do (return (values (ensure-keyword (sixth row)) - (parse-integer (seventh row) :junk-allowed t) - (parse-integer (ninth row) :junk-allowed t) - (parse-integer (nth 10 row) :junk-allowed t)))))) + do + (let ((size (seventh row)) + (precision (ninth row)) + (scale (nth 10 row))) + (return (values (ensure-keyword (sixth row)) + (when size (parse-integer size)) + (when precision (parse-integer precision)) + (when scale (parse-integer scale)))))))) (defmethod database-set-sequence-position (sequence-name (position integer) @@ -355,5 +359,5 @@ ;; nothing to do t) -(when (clsql-base-sys:database-type-library-loaded :odbc) - (clsql-base-sys:initialize-database-type :database-type :odbc)) +(when (clsql-base:database-type-library-loaded :odbc) + (clsql-base:initialize-database-type :database-type :odbc))