Commit Graph

58 Commits

Author SHA1 Message Date
Jinzhu 60b769c2c8 OnConflict UpdateAll includes fields that specified default values via tag 2021-01-04 15:13:56 +08:00
Jinzhu 79864af9ff Allow customize auto increment increment 2020-12-30 11:16:40 +08:00
Jinzhu 0f00493c50 Continue to update tracking fields even not selected with Select, but skip them if omited with Omit, fix #3856 2020-12-15 11:18:29 +08:00
Jinzhu 9df9f7688b Change UpdatingColumn to SkipHooks 2020-11-17 17:49:43 +08:00
Jinzhu f6e1786ca2 Add skip hooks support 2020-11-17 15:19:58 +08:00
Jinzhu f5c2126c29 Fix FindInBatches tests 2020-11-17 13:14:34 +08:00
Jinzhu 62be27d3ca Add OnConflict UpdateAll support 2020-11-16 20:22:08 +08:00
Jinzhu 1e241aa645 Reduce GC alloc 2020-11-10 21:23:20 +08:00
Jinzhu c0de3c5051 Support FullSaveAssociations Mode, close #3487, #3506 2020-09-24 19:29:15 +08:00
Jinzhu 28121d4455 Fix panic when batch creating from slice contains invalid data, close #3385 2020-09-03 20:59:41 +08:00
Jinzhu 48b395b760 returns ErrEmptySlice when creating with zero length slice 2020-09-03 11:32:30 +08:00
Jinzhu b4166d9515 Fix V2 Save compatibility, close #3332 2020-08-30 10:21:11 +08:00
Jinzhu 7a90496701 Test create from sql expr with map 2020-08-27 16:27:59 +08:00
Jinzhu ce8853e7a6 Add GormValuer interface support 2020-08-27 15:03:57 +08:00
Jinzhu 50826742fd Add error gorm.ErrInvalidData 2020-08-18 18:00:36 +08:00
Jinzhu 9fcc337bd1 Fix create from map 2020-08-17 17:41:36 +08:00
Jinzhu 3df249c127 Use table expr when inserting table, close #3239 2020-08-06 17:12:31 +08:00
Jinzhu 69d8111893 Fix panic when using invalid data, close #3193 2020-07-24 08:32:50 +08:00
Jinzhu c3f52cee8b Don't scan last insert id 0 2020-07-23 23:56:13 +08:00
Jinzhu 6ed697dd02 TestFirstOrCreateWithPrimaryKey, close #3192 2020-07-23 23:41:56 +08:00
Jinzhu 0546b59743 Fix save many2many associations with UUID primary key, close #3182 2020-07-22 11:28:00 +08:00
Jinzhu f5566288de Add SetColumn, Changed method 2020-06-30 16:53:54 +08:00
Jinzhu a1e35bdc94 Support merge batch data some having primary values 2020-06-20 16:52:15 +08:00
Jinzhu 0d58d5a3a7 Upsert selected columns 2020-06-10 10:48:48 +08:00
Jinzhu f3424c6864 Support save slice of data 2020-06-10 00:02:14 +08:00
Jinzhu 05e6a65ee1 Fix typo 2020-06-09 12:00:43 +08:00
Jinzhu c4872cddfd Refactor callbacks 2020-06-09 10:17:24 +08:00
Jinzhu 9f19378304 Grow SQL capacity to reduce allocation 2020-06-08 20:23:47 +08:00
Jinzhu aaf0725771 Refactor for performance 2020-06-08 17:21:26 +08:00
Jinzhu 1490a062db Refactor codebase and add benchmark test 2020-06-05 23:26:56 +08:00
Jinzhu 163200d05f Test Hooks 2020-06-05 20:24:15 +08:00
Jinzhu e986371a42 Rename package name 2020-06-02 09:18:01 +08:00
Jinzhu e490e09db5 Add SetupJoinTable support 2020-06-01 23:58:22 +08:00
Jinzhu 4e147e1256 Test SubQuery 2020-06-01 21:26:23 +08:00
Jinzhu befef0c9a9 Improve Hooks 2020-06-01 00:12:20 +08:00
Jinzhu 1546f8a4a1 Test CreateWithNoGORMPrimayKey 2020-05-31 12:52:49 +08:00
Jinzhu 1e7eb12cba Test empty struct 2020-05-31 11:19:45 +08:00
Jinzhu 55074213bc Add SoftDelete support 2020-05-29 07:35:45 +08:00
Jinzhu cc064f26ee Add on conflict support 2020-05-25 23:11:42 +08:00
Jinzhu 2ca4e91d88 Fix LastInsertID with string primary key 2020-05-23 18:38:55 +08:00
Jinzhu fb44625c33 Save HasOne association 2020-04-17 08:23:47 +08:00
Jinzhu 56ca9a87e0 Add permission check when create associations 2020-04-16 10:29:18 +08:00
Jinzhu 345ff7577c Save before associations 2020-04-15 23:58:26 +08:00
Jinzhu 29cd35219f Add creatable, updatable, readable permission 2020-04-08 08:15:00 +08:00
Jinzhu f7f633590f Fix tests with mysql, postgres 2020-03-12 13:05:22 +08:00
Jinzhu a145d7e019 Refactor structure 2020-03-09 14:25:50 +08:00
Jinzhu e2a360b9fa Add Before/After callbacks 2020-02-23 21:22:35 +08:00
Jinzhu fa22807e12 Make inesrt into db works 2020-02-23 19:41:29 +08:00
Jinzhu 43ce0b8af2 Handle create with default db values 2020-02-20 10:13:26 +08:00
Jinzhu 15ce5b3cdd Add create value converter 2020-02-20 10:12:10 +08:00