skip to Main Content

Postgresql – GORM Many-to-Many Relationship Not Creating Join Table Entries

this is what my playlist and user's models looks like type Playlist struct { ID uuid.UUID `json:"id" gorm:"primaryKey;type:uuid;default:gen_random_uuid()"` CreatedAt time.Time `json:"created_at"` UpdatedAt time.Time `json:"updated_at"` DeletedAt gorm.DeletedAt `json:"deleted_at" gorm:"index"` Title string `json:"title" gorm:"not null"` // Many 2 many with Back Reference…

VIEW QUESTION
Back To Top
Search