Fixed #16731 -- Made pattern lookups work properly with F() expressions

See https://code.djangoproject.com/ticket/16731#comment:11
Would it work to use [`bulk_create`](https://docs.djangoproject.com/en/dev/ref/models/querysets/#bulk-create) instead of calling create multiple times? Like this it would execute only one query.

```python
self.employees = Employee.objects.bulk_create(
    Employee(firstname="%Joh\\nny", lastname="%Joh\\n"),
    ...
)
```