[Newbie] Advanced expressions

From: Giulio Cesare Solaroli (slrgcs..bn-italy.com)
Date: Mon Sep 29 2003 - 05:41:45 EDT

  • Next message: Mike Kienenberger: "Re: [Newbie] Advanced expressions"

    Hi all,

    I am a newbie of Cayenne, so please forgive me if these questions
    sounds stupid.
    I have a good experience using EOF 4.5.1 with Objective-C and I am
    trying to replicate some of the extensions we have written to EOF
    (http://ibn.sf.net for an old snapshot of our code, never updated as
    the nobody expressed any attention to it) in Cayenne.

    In EOF we have written a few qualifiers (in Cayenne they are called
    expressions, if I get it right) like:
    - empty relationship;
    - not empty relationship;
    - match all values;
    - no match for value;

    Plus, we have extended the editing context (in Cayenne it should be the
    DataContext) to implement a few method to:
    - return the number of records/objects matching a given
    qualifier/expression (select count(*));
    - return if a given expression matches any value (select dummy from
    dual where exists(...); similar to a select count(*) checking if the
    result is greater than zero, but much more efficient, as it returs as
    soon as it finds a match).

    I didn't find any of these feature rightly available on Cayenne; is
    this right or did I miss something?
    If I would like to start implementing these feature which part of the
    Cayenne source three should I point my attention to?

    Thanks for your attention.

    Giulio Cesare Solaroli

    PS: I perfectly understand that all of the above is available through
    raw SQL, but it would be a real shame to waste all the informations
    already available on the model to write raw SQL.



    This archive was generated by hypermail 2.0.0 : Mon Sep 29 2003 - 05:42:02 EDT