MagmaCollectionReader sortBy: total number of elements in list?

Bart Gauquie bart.gauquie at gmail.com
Thu Dec 10 19:49:38 UTC 2009


Hi Chris,

Thanks for your clarifications.


You are absolutely right about the fact that it is madness to launch a query
which would load 7000 items. I was just trying the limits of the system.
Furthermore, I am coming from a Java world where we use a relational db
every day; there I'm used to filter out of millions of entries some objects
you need, and this relational database is actually very fast at that. The
point you make about linking the TODO's to a specific user is off course the
way you would do it in an object database using a rich domain. The idea
about moving TODO's from one collection to another collection (the history)
is also sound. Instead of changing the status field on a TODO (and filter on
that status), just move it to the history. Like this, you never end up with
a collection of many thousands of items. Just need to think more OO when
modeling the domain. And don't care how it gets persisted :-).

The 'toy' projects I've created with Magma don't have a rich domain. But on
my job we're investigating Smalltalk/Seaside & we've decided that we will
use Magma as a database. We are building a kind-off bigger POC. (
http://www.squeaksource.com/SunnysidePlanning2).


| Hmm, I pretty sure it can't know which of the 6065 elements matching a
| complex query expression the lowest of a particular key..  Sorry.

If I understand you correctly on this, it means that even if the sorting for
instance says: 200/2999, that if I read the first 20 items, these might
still change afterwards, so I should warn the user that these are
preliminary results. Or offcourse use #sortedBy:.


Kind Regards,

Bart
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/magma/attachments/20091210/b480be34/attachment.htm


More information about the Magma mailing list