You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible but with the columns? this is because the data-model of the project already have stablished the namesof the fields, and for example we don't have updated_at but ModificationTimestamp so, how can I do it?
The text was updated successfully, but these errors were encountered:
// Overriding Column NametypeAnimalstruct {
AnimalIdint64`gorm:"column:beast_id"`// set column name to `beast_id`Birthday time.Time`gorm:"column:day_of_the_beast"`// set column name to `day_of_the_beast`Ageint64`gorm:"column:age_of_the_beast"`// set column name to `age_of_the_beast`
}
@smacker Hi, thank you. But I exactly am trying to make gorm to take other name for the columns that are autocreated: created_at, updated_at, id. I tried what you said but it gave error because for example the column created_at is already especified: column "created_at" specified more than once)
Hi, is possible to override the name the columns: ID, created_at, updated_at, deleted_at ?
As far as I know I can set for example the name of the table with the function:
Is it possible but with the columns? this is because the data-model of the project already have stablished the namesof the fields, and for example we don't have updated_at but ModificationTimestamp so, how can I do it?
The text was updated successfully, but these errors were encountered: