Hi all,
I have recently done a manual insert into the Postgres DB which is usually handled by Django ORM. Today it is time for Django to insert, the above error is showing.
The Django model is shown here. There are no other keys except for the id.
class CashPosition(models.Model):
date = models.DateField()
volume_type = models.CharField(max_length=24)
sq = models.BooleanField()
buy_positions = models.IntegerField()
sell_positions = models.IntegerField()
net_positions = models.IntegerField()
What is the best way to overcome this problem?
Do I delete the data that I imported in and use django shell to do the insert?
Thanks!