Open titans-fangyu opened 11 months ago
When I upgrade github.com/uptrace/bun from v1.0.19 to v1.1.14, the following code no longer works and cannot get the Id after inserting data. this is bug ???
books := []Book{book1, book2} res, err := db.NewInsert().Model(&books).Exec(ctx) if err != nil { panic(err) } for _, book := range books { fmt.Println(book.ID) // book id is scanned automatically }
books := []Book{book1, book2} res, err := db.NewInsert().Model(&books).Exec(ctx) if err != nil { panic(err) }
for _, book := range books { fmt.Println(book.ID) // book id is scanned automatically }
Id intbun:"id,pk,autoincrement"`` The new version needs to be tagged...
Id int
When I upgrade github.com/uptrace/bun from v1.0.19 to v1.1.14, the following code no longer works and cannot get the Id after inserting data. this is bug ???