Hi Djangoists,

I have a model "question" which has a one-to-many relationship with
"answer".

class Question(models.Model):
    text = models.TextField()

class Answer(models.Model):
    text = models.TextField()
    question = models.ForeignKey(Question)

I can't figure out how to construct a filter that will give me

- just questions where there isn't an answer
- just questions where there is an answer

Is this really easy and I'm just not seeing it?

Thanks,
Jim

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

Reply via email to