[Django]-Django error using pagination and raw queryset

5👍

You should return the list instead of raw queryset.

def get_queryset(self):
    return list(Message.objects.raw('SELECT * FROM ertaapp_message where to_prof_id=%s ORDER BY create_date DESC',[self.request.user.id]))
👤numrut

Leave a comment