UUID field added after data already in database. Is there any way to populate the UUID field for existing data?

前端 未结 3 1725
轻奢々
轻奢々 2021-02-04 04:40

I\'ve added a UUID field to some of my models and then migrated with South. Any new objects I create have the UUID field populated correctly. However the UUID fields on all my o

3条回答
  •  野的像风
    2021-02-04 05:04

    There is now an excellent, updated answer for Django 1.9 to this exact question in the Django docs.

    Saved me a lot of time!

提交回复
热议问题