Gorm go build fail UnsafePointer

Discussed in https://github.com/go-gorm/gorm/discussions/6538Originally posted by **SunnyDate** August 22, 2023go versio...

Gorm Unable to Override Foreign Key and Preload with HasMany

Your QuestionHi Colleagues,I am trying to preload a slice of models as per documented. I have a has-many relationship in...

Gorm MySQL Migration - OnUpdate / OnDelete CASCADE not being applied to schema

Hi! Firstly, thanks for a great library, it is really intuitive and the documentation is excellent.However, I am having ...

Gorm Setting default values conflicts with automatic timestamps

type test struct{ CreatedAt int `gorm:"type:int unsigned;not null;default:0" json:"created_at"...

Gorm Does gorm support locking tables for access exclusive mode ?

My QuestionI have two tables like the following.type RuntimeCluster struct { ID string `gorm:"pr...

Gorm Raw() and Scan() api when using in Concurrent coroutine may cause various sql errors unexpectd and sporadically

Raw() and Scan() api when using in Concurrent coroutine may cause various sql errors unexpectd and sporadicallycurrent ...

Gorm How to get auto increment pk

Your QuestionHow to get auto increment pk in Raw SQLComment From: github-actions[bot]This issue has been automatically m...

Gorm Scanning results into composite structs does not match v1 behaviour

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/32DescriptionScanning join results into a struct containi...

Gorm 为什么Valuer接口只能用值接收器实现?

如题,为什么Valuer接口只能用值接收器实现?// 实现 driver.Valuer 接口,Value 返回 json valuefunc (j JSON) Value() (driver.Value, error) { if len(...

Gorm gorm batch update question

I can use this code to realize update for " update set amount = amount -1 where id = 1"tx.Table(dao.TInvoiceExpense).Whe...

Gorm COUNT() on joined table not omitting deleted rows?

Your QuestionHow to perform count on association without including the deleted rows.The document you expected this shoul...

Gorm any one see this error: “Error 1064: prepared statements not allowed with access_mode = 'auto'”

Your QuestionIn MySQL8.0.31, in MGR mode, the following error occurred:Error 1064: prepared statements not allowed with ...

Gorm UpdatedAt set during Create

Your QuestionWhy does UpdatedAt get set during a Create, and how can I disable UpdatedAt being set just for a CreateCREA...

Gorm How to solve computed a field?

Your Questionhow to solve computed a field? My solvetype Exam struct { ID int Name string Point string}db.raw("select id...

Gorm Does Gorm crash on multiple concurrent writes, or is it my code ?

Your Questioni have written a Golang Import Script that uses a workerpool for concurrent usage, together with the great ...

Gorm endless loop in Save

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/684DescriptionCalling Save with a pointer to an interface...

Gorm Does gorm support partition

Hello,Does gorm support partition? For example:create table employees ( id int not null, fname varchar(30), lna...

Gorm Transaction update RowsAffected is 0

Your QuestionGorm: v1.25.5Go: 1.21.4 MySQL: 8.0.31A similar issue from https://github.com/go-gorm/gorm/issues/2038, and ...

Gorm GORM v2 Many to Many does not create new record in join table

Your QuestionTwo structs Thread & Interest have a many to many relationship with each other. According to the docume...

Gorm Is it normal that select queries are so slow?

Your QuestionWhile using gorm a select of a small struct(29 members) takes almost 400ms, When using phpmyadmin, database...
上一页 下一页
.