Loading from pickled data causes database error with new saves

Posted by hibbie on Stack Overflow See other posts from Stack Overflow or by hibbie
Published on 2010-05-12T19:17:42Z Indexed on 2010/05/12 19:44 UTC
Read the original article Hit count: 181

Filed under:
|
|
|

In order to save time moving data I pickled some models and dumped them to file. I then reloaded them into another database using the same exact model. The save worked fine and the objects kept their old id which is what I wanted. However, when saving new objects I run into nextval errors.

Not being very adept with postgres, I'm not sure how to fix this so I can keep old records with their existing ID while being able to continue adding new data.

Thanks, Thomas

© Stack Overflow or respective owner

Related posts about django-models

Related posts about django