Stephano George
a3cc6c6088
Fix: wrong value when Find with Join with same column name, close #5723 , #5711
2022-09-30 17:18:42 +08:00
Cr
101a7c789f
fix: scan array ( #5624 )
...
Co-authored-by: Jinzhu <wosmvp@gmail.com>
2022-09-22 15:51:47 +08:00
jesse.tang
1f634c3937
support scan assign slice cap ( #5634 )
...
* support scan assign slice cap
* fix
2022-09-22 14:50:35 +08:00
jesse.tang
f78f635fae
Optimize: code logic db.scanIntoStruct() ( #5633 )
2022-09-05 15:34:33 +08:00
Cr
8d45714628
fix: reset null value in slice ( #5417 )
...
* fix: reset null value in slice
* fix: can not set field in-place in join
2022-06-14 13:48:50 +08:00
Bexanderthebex
d01de7232b
enhancement: Avoid calling reflect.New() when passing in slice of values to `Scan()` ( #5388 )
...
* fix: reduce allocations when slice of values
* chore[test]: Add benchmark for scan
* chore[test]: add bench for scan slice
* chore[test]: add bench for slice pointer and improve tests
* chore[test]: make sure database is empty when doing slice tests
* fix[test]: correct sql delete statement
* enhancement: skip new if rows affected = 0
2022-06-01 11:50:57 +08:00
Cr
7e13b03bd4
fix: duplicate column scan ( #5369 )
...
* fix: duplicate column scan
* fix: dup filed in inconsistent schema and database
* chore[ci skip]: gofumpt style
* chore[ci skip]: fix typo
2022-05-28 22:18:07 +08:00
Filippo Del Moro
6aa6d37fc4
Fix scanIntoStruct ( #5241 )
...
* Reproduces error case
* Fix scanIntoStruct
Co-authored-by: Filippo Del Moro <filippo.delmoro@facile.it>
2022-04-13 15:47:04 +08:00
Hasan
81c4024232
Offset issue resolved for scanning results back into struct ( #5227 )
2022-04-07 23:56:41 +08:00
Jinzhu
9dd6ed9c65
Scan with Rows interface
2022-03-29 18:14:37 +08:00
Jinzhu
f92e6747cb
Handle field set value error
2022-03-23 17:24:25 +08:00
Hasan
f3e2da5ba3
Added offset when scanning the result back to struct, close #5143
...
commit 9a2058164d44c98d7b586b87bed1757f89d6fad7
Author: Jinzhu <wosmvp@gmail.com>
Date: Thu Mar 17 22:34:19 2022 +0800
Refactor #5143
commit c259de2176
Author: Hasan <mr.k779@outlook.com>
Date: Mon Mar 14 20:04:01 2022 +0545
Update scan_test.go
commit 09f127b491
Author: Hasan <mr.k779@outlook.com>
Date: Mon Mar 14 19:23:47 2022 +0545
Added test for scanning embedded data into structs
commit aeaca493cf
Author: Hasan <mr.k779@outlook.com>
Date: Tue Mar 8 04:08:16 2022 +0600
Added offset when scanning the result back to struct
2022-03-17 22:52:40 +08:00
Jinzhu
e2e802b837
Refactor Scan
2022-02-28 13:00:30 +08:00
Jinzhu
43a72b369e
Refactor Scan
2022-02-28 00:16:57 +08:00
Jinzhu
68bb5379d9
Refactor scan into struct
2022-02-27 09:09:29 +08:00
chenrui
397b583b8e
fix: query scanner in single column
2022-02-25 22:38:48 +08:00
Jinzhu
39d84cba5f
Add serializer support ( #5078 )
...
* Update context
* Update GormFieldValuer
* Add Serializer
* Add Serializer Interface
* Refactor gorm field
* Refactor setter, valuer
* Add sync.Pool
* Fix test
* Add pool manager
* Fix pool manager
* Add poolInitializer
* Add Serializer Scan support
* Add Serializer Value method
* Add serializer test
* Finish Serializer
* Fix JSONSerializer for postgres
* Fix JSONSerializer for sqlserver
* Test serializer tag
* Add unixtime serializer
* Update go.mod
2022-02-19 17:02:53 +08:00
Jinzhu
270e38c518
Fix duplicated error when Scan, close #4525
2021-11-29 14:23:10 +08:00
heige
9d5f315b6d
feat: go code style adjust and optimize code for callbacks package ( #4861 )
...
* feat: go code style adjust and optimize code for callbacks package
* Update scan.go
2021-11-29 09:33:20 +08:00
Jinzhu
9635d25150
Fix query with uninitialized map
2021-11-01 13:00:52 +08:00
Jinzhu
9f533950a2
Add dest value if current size equal zero
2021-10-28 17:12:31 +08:00
Jinzhu
e953880d19
Add returning tests
2021-10-28 09:17:33 +08:00
Jinzhu
835d7bde59
Add returning support to delete
2021-10-28 07:56:55 +08:00
Jinzhu
af3fbdc2fc
Improve returning support
2021-10-26 22:40:14 +08:00
Jinzhu
ab355336cb
Fix scan with interface
2021-09-17 18:35:14 +08:00
Jinzhu
12bbde89e6
Fix Scan with interface
2021-09-17 14:04:19 +08:00
Jinzhu
c73fe96cfd
Fix scan into decimal.Decimal, close #4457
2021-07-13 19:59:31 +08:00
Jinzhu
b616d810eb
Fix scan single value to custom type, close #4501
2021-07-13 19:29:10 +08:00
Jinzhu
673053f56a
Fix context cancel error, close #4259 , close #4260
2021-04-09 10:21:01 +08:00
Ben
cc61202fe2
retrieving gorm object support pointer ( #4006 )
2021-01-27 11:50:15 +08:00
Jinzhu
81aa949105
Remove the uncessary reflect.Ptr
2021-01-27 11:48:47 +08:00
rorschach
ba59065024
retrieving gorm object support pointer
2021-01-27 11:48:47 +08:00
SmallTianTian
41e52f343a
fix: scan more base type and sql.NullXXX ( #3813 )
2020-12-02 14:00:16 +08:00
Dakatan
acedbb8310
Fix Scan int32, uint32 ( #3801 )
2020-11-30 10:09:08 +08:00
Jinzhu
1e241aa645
Reduce GC alloc
2020-11-10 21:23:20 +08:00
Jinzhu
9eec6ae066
Fix affected rows for Scan, change affected rows count for row/rows to '-', close #3532
2020-09-27 12:25:38 +08:00
Jinzhu
ba253982bf
Fix Pluck with Time and Scanner
2020-09-24 20:08:24 +08:00
Jinzhu
02fb382ec0
Support scan into int, string data types
2020-09-11 15:01:02 +08:00
Jinzhu
e73147fa8e
Better support for scan into map, fix unfriendly data type for interface, close #3351
2020-09-01 17:45:14 +08:00
Jinzhu
9075b33620
Query with smaller struct
2020-07-01 08:56:21 +08:00
Jinzhu
9039e36cfc
Allow scan into float close #1373
2020-06-14 19:18:48 +08:00
Jinzhu
22ff8377df
Fix Pluck with Table only
2020-06-09 15:36:10 +08:00
Jinzhu
aaf0725771
Refactor for performance
2020-06-08 17:21:26 +08:00
Jinzhu
b32658358c
Fix can't scan null value into normal data types
2020-06-03 09:00:20 +08:00
Jinzhu
94685d1024
Fix can't scan null value into normal data types
2020-06-02 23:30:26 +08:00
Jinzhu
e986371a42
Rename package name
2020-06-02 09:18:01 +08:00
Jinzhu
95a6539331
Test Pluck
2020-05-31 21:11:20 +08:00
Jinzhu
2b56fa0472
Fix Scanner tests on mssql
2020-05-31 01:21:16 +08:00
Jinzhu
6f4602af11
Fix mysql tests
2020-05-29 23:38:03 +08:00
Jinzhu
5be642a435
Add ScanRows support
2020-05-26 23:13:05 +08:00