When parsing database data, should []byte
always be parsed???
#251
Labels
Question
Indicates that an issue, pull request, or discussion needs more information
在使用一些复杂的 SQL 时,如:时间分组、自定义字段等,非基础类型的字段值通常会被设置为
[]byte
,我们需要自行实现Scanner
接口解析其值,但是在 carbon 中,只解析值为time.Time
类型,并未解析[]byte
,导致使用复杂 SQL 时,无法实现解析See: https://github.com/golang-module/carbon/blob/165bda517b50bc3fd41f952c0d53c7478fbf2db3/database.go#L10-L21
The text was updated successfully, but these errors were encountered: