Can I filter a django model with a python list?
- by Rhubarb
Say I have a model object 'Person' defined, which has a field called 'Name'. And I have a list of people:
l = ['Bob','Dave','Jane']
I would like to return a list of all Person records where the first name is not in the list of names defined in l.
What is the most pythonic way of doing this?