Re: "is null" qualifier not working in modeler

From: Gili (cowwo..bs.darktech.org)
Date: Fri Sep 09 2005 - 11:54:36 EDT

  • Next message: Andrus Adamchik: "Re: "is null" qualifier not working in modeler"

            Well, I know that MySQL (which I use) expects "is null" but when I
    enter this in modeler the field turns red (indicating invalid syntax)
    and it rejects the value. So either this is a modeler bug or a Cayenne
    one because I honestly don't see how I'm supposed to get this working :)
    in-so-far as I'm concerned it would be great if I could consistently
    enter "= null" in the modeler and Cayenne would translate it to the
    appropriate syntax for me. Looking at the code, I'm pretty sure that's
    sort of what it was meant to do.

    Gili

    Mike Kienenberger wrote:
    > Qualifier null handling is database-dependent.
    > Some databases require "is null" and some require "= null" while some
    > will accept both.
    >
    > You'd either have to explicitly choose the supported type for your
    > query or (probably better) use "value = $nullValue" and set $nullValue
    > to null in your use of the qualifier. That should allow Cayenne to
    > correctly choose the right operator.
    >
    > On 9/9/05, Gili <cowwo..bs.darktech.org> wrote:
    >
    >>Hi,
    >>
    >> I've declared a SelectQuery in the modeler. The qualifier is set to
    >>"parent = null" where "parent" is a to-one relationship. Anyway, at
    >>runtime with logging enabled I can see that "parent is null" is never
    >>passed onto the SQL query, as a result I am getting results back where
    >>the parent is non-null. I am invoking the query using:
    >>
    >>context.performQuery("DefaultTheme.getRoot", false);
    >>
    >> it does not take any parameters. I tried searching the mailing list but
    >>found no mention of this. Is my qualifier syntax wrong or is something
    >>wrong with the modeler?
    >>
    >>Thank you,
    >>Gili
    >>--
    >>http://www.desktopbeautifier.com/
    >>
    >
    >

    -- 
    http://www.desktopbeautifier.com/
    



    This archive was generated by hypermail 2.0.0 : Fri Sep 09 2005 - 11:54:35 EDT