[Answer]-How can I add user `first_name` in this queryset? (this is incorrect)

1👍

You can use double-underscore notation to follow ForeignKey relationship:

Q(user__first_name__contains)

Hope that helps.

👤alecxe

Leave a comment