Gorm rename column not working

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/768DescriptionI have a column in the database named NAME ...

Gorm How to close file handle on a local sqlite db?

Your QuestionI'm using Gorm to access a sqlite db from the local filesystem. I'm writing tests now that require me to cr...

Gorm Support for SurrealDB

We need support for SurrealDBMotivationRelated IssuesComment From: github-actions[bot]The issue has been automatically m...

Gorm updates report an error: Lock wait timeout exceeded; try restarting transaction

libs: gorm.io/driver/mysql v1.5.6 gorm.io/gorm v1.25.10 gorm.io/plugin/dbresolver v1.5.2go: 1.21mysql: 8.0dbconf...

Gorm 使用timestamp类型查询的时候报错: unsupported Scan, storing driver.Value type []uint8 into type *time.Time

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/1DescriptionDDL如下:CREATE TABLE `account` ( `id` int NOT ...

Gorm Save time.Time type data(local time) with pg timestamp(without timezone) type,fetched data is not correct(force marked as UTC)

Your Questionwhen insert time.Time(with client timezone) data into pg timestamp(without timezone) column,then fetch it,g...

Gorm Is there a test coverage report for gorm?

Your QuestionWe are investigating gorm and considering using it, just wondering what is the current test coverage of the...

Gorm Defing models with foreign entities

Your Questiontype RealWorkout struct { gorm.Model TemplateID int Template Workout WorkoutID int}I have an...

Gorm How to order fields in DoUpdates?

Your QuestionHello, How do I make sure calculate b before calculate a?DoUpdates: clause.Assignments(map[string]interface...

Gorm Using an @ in a string passed to Select results in incorrect query

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/764DescriptionWhen using the @ character in a string pass...

Gorm Allow for the creation of custom "finishers"

Describe the featureAs a user of gorm, I can extend its capabilities with custom "finishers" (in the gorm parlance).I th...

Gorm How to create Postgres index with "NULLS NOT DISTINCT"?

How would I create a Postgresql index with NULLS NOT DISTINCT option in gorm?Tried it with gorm:"index:,option:NULLS NOT...

Gorm when gorm not connected to any DB; the query execute result has no error

GORM Playground Linkhttps://github.sheincorp.cn/go-gorm/playground/pull/1Descriptionwhen gorm connect to a wrong dsn con...

Gorm Location set to "" for time.Time fields apart from created at and update at

Your QuestionI am using Postgres and when I declare a struct with a field of type time.Time, the location is set to "" ...

Gorm Updating UpdateAt with .Save does not use the given value

GORM Playground LinkI will add the link later, can't do it now, but I think the description is enough to understand the ...

Gorm Commands out of sync; you can't run this command now

Your QuestionOccasional errors: Commands out of sync; you can't run this command nowHow to solveComment From: ivilaMaybe...

Gorm Field Overwriting Issue with Embedded Structs in GORM

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/1DescriptionWhen using GORM to map structs to a database,...

Gorm Failed to auto migrate, but got error Error 1170: BLOB/TEXT column 'user_refer' used in key specification without a key length

Descriptionwhen i used User.Name for primary_key,call AutoMigrate() will got error,like this:2020/09/03 15:05:30 /Users...

Gorm FirstOrCreate doesn't behave as expected

GORM Playground Linkhttps://github.com/go-gorm/playground/pull/765DescriptionFirstOrCreate doesn't behave like FirstOrIn...

Gorm duplicate join clause when using scan() + count(), find() + count() is normal

Description var count int64 var tempList []int test := global.GetTransaction().Table(e.TableName() + "...
上一页 下一页
.