* db-mysql/mysql-api.lisp: Fix int vs. long slots in foreign
structures found by testing with AllegroCL 7.0b AMD64.
* db-*/*-loader.lisp: Load 64-bit libraries on 64-bit platorms
- * sql/objects.lisp: Initial caching support for SELECT
+ * sql/objects.lisp: Simple implementation of UPDATE-OBJECT-JOINS.
+ Initial caching support for SELECT
* tests/test-oodml.lisp: Avoid using cache when testing select.
* sql/kmr-mop.lisp: Explicitly check slot order and
store as a cl:*feature*
COMMONSQL SPEC
-* Missing:
-
- UPDATE-OBJECT-JOINS
-
* Incompatible
>> The functional sql interface
o variables (e.g., table identifiers) should be instantiated at runtime
-OPTIMIZATIONS
+VARIANCES FROM COMMONSQL
+
+UPDATE-OBJECT-JOINS:
+ Rather than simply reading the values for each
+ object, to meet CommonSQL spec need to generate a single
+ query to read values for all objects, up to max-len count.
+
+OPTIMIZATIONS
+
* Revisit result-type list creation,perhaps caching
POSSIBLE EXTENSIONS
(defun update-object-joins (objects &key (slots t) (force-p t)
class-name (max-len *default-update-objects-max-len*))
- "Updates the remote join slots, that is those slots defined without :retrieval :immediate."
+ "Updates the remote join slots, that is those slots defined without
+:retrieval :immediate."
(when objects
(unless class-name
- (class-name (class-of (first objects))))
+ (setq class-name (class-name (class-of (first objects)))))
(let* ((class (find-class class-name))
(deferred-joins (generate-retrieval-joins-list class :deferred)))
- (when deferred-joins
- (warn "not yet implemented.")
- ))))
+ (cond
+ (deferred-joins
+ (mapcar
+ #'(lambda (slotdef)
+ ;; FIXME: Rather than simply reading the values for each
+ ;; object, to meet CommonSQL spec need to generate a single
+ ;; query to read values for all objects, up to max-len count
+ (mapcar
+ #'(lambda (object)
+ (slot-value object (slot-definition-name slotdef)))
+ objects))
+ deferred-joins))
+ (t
+ (warn "Class ~A does not have any deferred join slots." class-name)))
+ )))
(defun fault-join-slot-raw (class object slot-def)