Saturday, September 11, 2010

Re: Filter for non-True NullBooleanField

On Sep 10, 2:43 pm, Christos Jonathan Hayward
<christos.jonathan.hayw...@gmail.com> wrote:
> P.S. Setting:
>
> .filter(is_invisible__in = [False, None])

how about:

.exclude(is_invisible__exact = True)

>
> is not working as intended; I seem to be getting no matches when I should be
> getting matches.
>
> On Fri, Sep 10, 2010 at 4:19 PM, Christos Jonathan Hayward <
>
>
>
>
>
> christos.jonathan.hayw...@gmail.com> wrote:
> > How can I filter for instances having a NullBooleanField that is not True
> > (i.e. is either False or a null)?
>
> > --
> > [image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
> > Christos Jonathan Hayward, an Orthodox Christian author.
>
> > Author Bio <http://jonathanscorner.com/author/> • Books<http://cjshayward.com/>
> >  • *Email <christos.jonathan.hayw...@gmail.com>* • Facebook<http://www.facebook.com/christos.jonathan.hayward>
> >  • LinkedIn <http://www.linkedin.com/in/jonathanhayward> • Twitter<http://twitter.com/JonathansCorner>
> >  • *Web <http://jonathanscorner.com/>* • What's New?<http://jonathanscorner.com/>
> > I invite you to visit my "theology, literature, and other creative works"
> > site.
>
> --
> [image: Christos Jonathan Hayward] <http://jonathanscorner.com/>
> Christos Jonathan Hayward, an Orthodox Christian author.
>
> Author Bio <http://jonathanscorner.com/author/> • Books<http://cjshayward.com/>
>  • *Email <christos.jonathan.hayw...@gmail.com>* •
> Facebook<http://www.facebook.com/christos.jonathan.hayward>
>  • LinkedIn <http://www.linkedin.com/in/jonathanhayward> •
> Twitter<http://twitter.com/JonathansCorner>
>  • *Web <http://jonathanscorner.com/>* • What's
> New?<http://jonathanscorner.com/>
> I invite you to visit my "theology, literature, and other creative works"
> site.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

No comments:

Post a Comment