“Too many SQL variables” error in django with sqlite3

后端 未结 6 1935
臣服心动
臣服心动 2020-12-10 00:23

I\'m getting this error using sqlite3 in django:

Exception Value: too many SQL variables

And I think the answer to it is this, from

6条回答
  •  感情败类
    2020-12-10 00:53

    I hava found the same error when I run the line:

        Entry.objects.all().delete()
    

    I solved the problem by

        while Entry.objects.count():
              Entry.objects.all()[0].delete()
    

    I think it's a better idea than others.

提交回复
热议问题