Consider the following situation: -
Suppose my app allows users to create the states / provinces in their country. Just for clarity, we are considering only ASCII ch
You can use lookup='iexact' in UniqueValidator on serializer, like this:
class StateSerializer(serializers.ModelSerializer): name = serializers.CharField(validators=[ UniqueValidator( queryset=models.State.objects.all(),lookup='iexact' )]
django version: 1.11.6