Changes between Version 2 and Version 3 of Ticket #36064, comment 4
- Timestamp:
- Jan 7, 2025, 2:49:08 AM (36 hours ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #36064, comment 4
v2 v3 13 13 # 1. Model.id has a default 14 14 foo = Model(id=1) 15 foo.save() .# INSERT15 foo.save() # INSERT 16 16 bar = Model(id=1) 17 bar.save() .# INSERT & IntegrityError17 bar.save() # INSERT & IntegrityError 18 18 19 19 # 2. Model.id doesn't have a default 20 20 foo = Model(id=1) 21 foo.save() .# UPDATE & INSERT21 foo.save() # UPDATE & INSERT 22 22 bar = Model(id=1) 23 bar.save() .# UPDATE23 bar.save() # UPDATE 24 24 }}}