[Fixed]-Django ForeignKeys not saving

1👍

I found the answer!

So the problem was followed. Im dealing with a legacy database in mySQL, the problem was that when django was assigning the client id it was thinking the primary key was an integer field, so when it tried assigning the key (which was a varchar) it ran into an integer field, so it didn’t like it and didn’t save. Hopefully that helps anyone who runs into this problem later!

Leave a comment