RE: get_or_delete leading to duplicate creation

2018-11-27 Thread Matthew Pava
Avoid using the created_at time in your get_or_create call. From: django-users@googlegroups.com [mailto:django-users@googlegroups.com] On Behalf Of Ankit Khandewal Sent: Tuesday, November 27, 2018 2:01 AM To: Django users Subject: get_or_delete leading to duplicate creation Hello, I am using

Re: get_or_delete leading to duplicate creation

2018-11-27 Thread Joel Mathew
You're talking as if this is a bug. If your records are being duplicated, the problem is your code. It's not unto django to gauge what you need to do in the database. Be explicit and update the records if you want updation. Sincerely yours, Joel G Mathew On Tue, 27 Nov 2018 at 18:07, Ankit

Re: get_or_delete leading to duplicate creation

2018-11-27 Thread Andréas Kühne
Hi Ankit, First - this is not the Django developers forum - it's a forum for getting help from other users :-) Second - I don't think this is an error in the underlying framework. get_or_create is used by many people (I use it in several places - especially in tests) - I would recommend that you