[elephant-devel] get-instance-by-value where value is a list

Ian Eslick eslick at media.mit.edu
Sat Sep 27 17:14:28 UTC 2008


Alex, you are quite right; compounds structures are compared on per- 
byte basis so identical serialized bitstreams compare correctly.   
There is no ordering mechanism, as Alex clarifies below.

Ian

On Sep 27, 2008, at 8:41 AM, Alex Mizrahi wrote:

> IE> Currently none of the stores support comparing lists.
>
> em, we do not support get-instances-by-range queries,
> but get-instance-by-value should be fine, as long as serialized
> representation of list is same.
>
> ELE-TESTS> (open-store *testbdb-spec*)
> #<BDB-STORE-CONTROLLER /home/alex/stix/lisp/vc/elephant/tests/testdb/>
>
> ELE-TESTS> (defpclass rsdrp ()
>     ((islot :accessor islot :initarg :islot :index t)))
> #<PERSISTENT-METACLASS RSDRP>
> ELE-TESTS> (make-instance 'rsdrp :islot (list 1 2))
> #<RSDRP oid:600>
> ELE-TESTS> (make-instance 'rsdrp :islot (list 3 4))
> #<RSDRP oid:603>
> ELE-TESTS> (make-instance 'rsdrp :islot (list 5 6))
> #<RSDRP oid:604>
> ELE-TESTS> (get-instance-by-value 'rsdrp 'islot (list 5 6))
> #<RSDRP oid:604>
> T
> ELE-TESTS> (get-instance-by-value 'rsdrp 'islot (list 1 2))
> #<RSDRP oid:600>
> T
> ELE-TESTS> (get-instance-by-value 'rsdrp 'islot (list 3 4))
> #<RSDRP oid:603>
> T
>
> works in db-postmodern too, and i guess should work with clsql.
>
> so either Frank has problems with some special form of lists,
> or maybe he means that it's get-instances-by-range which is broken.
> _______________________________________________
> elephant-devel site list
> elephant-devel at common-lisp.net
> http://common-lisp.net/mailman/listinfo/elephant-devel




More information about the elephant-devel mailing list