projects
/
clsql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
a45efdc
)
r9410: fix case where reading a float which is already convert to a float by the...
author
Kevin M. Rosenberg
<kevin@rosenberg.net>
Thu, 20 May 2004 09:06:14 +0000
(09:06 +0000)
committer
Kevin M. Rosenberg
<kevin@rosenberg.net>
Thu, 20 May 2004 09:06:14 +0000
(09:06 +0000)
sql/objects.lisp
patch
|
blob
|
history
diff --git
a/sql/objects.lisp
b/sql/objects.lisp
index 5e36e758bf9ed8b33c93f9280465fa0e0a928d67..07652f21c7f77d7712b35ddde07da23a5c945997 100644
(file)
--- a/
sql/objects.lisp
+++ b/
sql/objects.lisp
@@
-690,7
+690,11
@@
superclass of the newly-defined View Class."
(defmethod read-sql-value (val (type (eql 'float)) database)
(declare (ignore database))
;; writing 1.0 writes 1, so we we *really* want a float, must do (float ...)
(defmethod read-sql-value (val (type (eql 'float)) database)
(declare (ignore database))
;; writing 1.0 writes 1, so we we *really* want a float, must do (float ...)
- (float (read-from-string val)))
+ (etypecase val
+ (string
+ (float (read-from-string val)))
+ (float
+ val)))
(defmethod read-sql-value (val (type (eql 'boolean)) database)
(case (database-underlying-type database)
(defmethod read-sql-value (val (type (eql 'boolean)) database)
(case (database-underlying-type database)
@@
-1124,6
+1128,9
@@
ENABLE-SQL-READER-SYNTAX."
target-args))))
(multiple-value-bind (target-args qualifier-args)
(query-get-selections select-all-args)
target-args))))
(multiple-value-bind (target-args qualifier-args)
(query-get-selections select-all-args)
+ (unless (or *default-database* (getf qualifier-args :database))
+ (signal-no-database-error nil))
+
(cond
((select-objects target-args)
(let ((caching (getf qualifier-args :caching t))
(cond
((select-objects target-args)
(let ((caching (getf qualifier-args :caching t))