Documentation ¶
Index ¶
- Variables
- func NewQuery(exec boil.Executor, mods ...qm.QueryMod) *queries.Query
- func NewQueryG(mods ...qm.QueryMod) *queries.Query
- func People(exec boil.Executor, mods ...qm.QueryMod) personQuery
- func PeopleG(mods ...qm.QueryMod) personQuery
- func PersonExists(exec boil.Executor, id int) (bool, error)
- func PersonExistsG(id int) (bool, error)
- func PersonExistsGP(id int) bool
- func PersonExistsP(exec boil.Executor, id int) bool
- func PetExists(exec boil.Executor, id int) (bool, error)
- func PetExistsG(id int) (bool, error)
- func PetExistsGP(id int) bool
- func PetExistsP(exec boil.Executor, id int) bool
- func Pets(exec boil.Executor, mods ...qm.QueryMod) petQuery
- func PetsG(mods ...qm.QueryMod) petQuery
- func SchemaMigrationExists(exec boil.Executor, version int64) (bool, error)
- func SchemaMigrationExistsG(version int64) (bool, error)
- func SchemaMigrationExistsGP(version int64) bool
- func SchemaMigrationExistsP(exec boil.Executor, version int64) bool
- func SchemaMigrations(exec boil.Executor, mods ...qm.QueryMod) schemaMigrationQuery
- func SchemaMigrationsG(mods ...qm.QueryMod) schemaMigrationQuery
- type M
- type Person
- func (o *Person) AddPets(exec boil.Executor, insert bool, related ...*Pet) error
- func (o *Person) AddPetsG(insert bool, related ...*Pet) error
- func (o *Person) AddPetsGP(insert bool, related ...*Pet)
- func (o *Person) AddPetsP(exec boil.Executor, insert bool, related ...*Pet)
- func (o *Person) Delete(exec boil.Executor) error
- func (o *Person) DeleteG() error
- func (o *Person) DeleteGP()
- func (o *Person) DeleteP(exec boil.Executor)
- func (o *Person) Insert(exec boil.Executor, whitelist ...string) error
- func (o *Person) InsertG(whitelist ...string) error
- func (o *Person) InsertGP(whitelist ...string)
- func (o *Person) InsertP(exec boil.Executor, whitelist ...string)
- func (o *Person) Pets(exec boil.Executor, mods ...qm.QueryMod) petQuery
- func (o *Person) PetsG(mods ...qm.QueryMod) petQuery
- func (o *Person) Reload(exec boil.Executor) error
- func (o *Person) ReloadG() error
- func (o *Person) ReloadGP()
- func (o *Person) ReloadP(exec boil.Executor)
- func (o *Person) RemovePets(exec boil.Executor, related ...*Pet) error
- func (o *Person) RemovePetsG(related ...*Pet) error
- func (o *Person) RemovePetsGP(related ...*Pet)
- func (o *Person) RemovePetsP(exec boil.Executor, related ...*Pet)
- func (o *Person) SetPets(exec boil.Executor, insert bool, related ...*Pet) error
- func (o *Person) SetPetsG(insert bool, related ...*Pet) error
- func (o *Person) SetPetsGP(insert bool, related ...*Pet)
- func (o *Person) SetPetsP(exec boil.Executor, insert bool, related ...*Pet)
- func (o *Person) Update(exec boil.Executor, whitelist ...string) error
- func (o *Person) UpdateG(whitelist ...string) error
- func (o *Person) UpdateGP(whitelist ...string)
- func (o *Person) UpdateP(exec boil.Executor, whitelist ...string)
- func (o *Person) Upsert(exec boil.Executor, updateOnConflict bool, conflictColumns []string, ...) error
- func (o *Person) UpsertG(updateOnConflict bool, conflictColumns []string, updateColumns []string, ...) error
- func (o *Person) UpsertGP(updateOnConflict bool, conflictColumns []string, updateColumns []string, ...)
- func (o *Person) UpsertP(exec boil.Executor, updateOnConflict bool, conflictColumns []string, ...)
- type PersonSlice
- func (o PersonSlice) DeleteAll(exec boil.Executor) error
- func (o PersonSlice) DeleteAllG() error
- func (o PersonSlice) DeleteAllGP()
- func (o PersonSlice) DeleteAllP(exec boil.Executor)
- func (o *PersonSlice) ReloadAll(exec boil.Executor) error
- func (o *PersonSlice) ReloadAllG() error
- func (o *PersonSlice) ReloadAllGP()
- func (o *PersonSlice) ReloadAllP(exec boil.Executor)
- func (o PersonSlice) UpdateAll(exec boil.Executor, cols M) error
- func (o PersonSlice) UpdateAllG(cols M) error
- func (o PersonSlice) UpdateAllGP(cols M)
- func (o PersonSlice) UpdateAllP(exec boil.Executor, cols M)
- type Pet
- func (o *Pet) Delete(exec boil.Executor) error
- func (o *Pet) DeleteG() error
- func (o *Pet) DeleteGP()
- func (o *Pet) DeleteP(exec boil.Executor)
- func (o *Pet) Insert(exec boil.Executor, whitelist ...string) error
- func (o *Pet) InsertG(whitelist ...string) error
- func (o *Pet) InsertGP(whitelist ...string)
- func (o *Pet) InsertP(exec boil.Executor, whitelist ...string)
- func (o *Pet) Person(exec boil.Executor, mods ...qm.QueryMod) personQuery
- func (o *Pet) PersonG(mods ...qm.QueryMod) personQuery
- func (o *Pet) Reload(exec boil.Executor) error
- func (o *Pet) ReloadG() error
- func (o *Pet) ReloadGP()
- func (o *Pet) ReloadP(exec boil.Executor)
- func (o *Pet) RemovePerson(exec boil.Executor, related *Person) error
- func (o *Pet) RemovePersonG(related *Person) error
- func (o *Pet) RemovePersonGP(related *Person)
- func (o *Pet) RemovePersonP(exec boil.Executor, related *Person)
- func (o *Pet) SetPerson(exec boil.Executor, insert bool, related *Person) error
- func (o *Pet) SetPersonG(insert bool, related *Person) error
- func (o *Pet) SetPersonGP(insert bool, related *Person)
- func (o *Pet) SetPersonP(exec boil.Executor, insert bool, related *Person)
- func (o *Pet) Update(exec boil.Executor, whitelist ...string) error
- func (o *Pet) UpdateG(whitelist ...string) error
- func (o *Pet) UpdateGP(whitelist ...string)
- func (o *Pet) UpdateP(exec boil.Executor, whitelist ...string)
- func (o *Pet) Upsert(exec boil.Executor, updateOnConflict bool, conflictColumns []string, ...) error
- func (o *Pet) UpsertG(updateOnConflict bool, conflictColumns []string, updateColumns []string, ...) error
- func (o *Pet) UpsertGP(updateOnConflict bool, conflictColumns []string, updateColumns []string, ...)
- func (o *Pet) UpsertP(exec boil.Executor, updateOnConflict bool, conflictColumns []string, ...)
- type PetSlice
- func (o PetSlice) DeleteAll(exec boil.Executor) error
- func (o PetSlice) DeleteAllG() error
- func (o PetSlice) DeleteAllGP()
- func (o PetSlice) DeleteAllP(exec boil.Executor)
- func (o *PetSlice) ReloadAll(exec boil.Executor) error
- func (o *PetSlice) ReloadAllG() error
- func (o *PetSlice) ReloadAllGP()
- func (o *PetSlice) ReloadAllP(exec boil.Executor)
- func (o PetSlice) UpdateAll(exec boil.Executor, cols M) error
- func (o PetSlice) UpdateAllG(cols M) error
- func (o PetSlice) UpdateAllGP(cols M)
- func (o PetSlice) UpdateAllP(exec boil.Executor, cols M)
- type SchemaMigration
- func FindSchemaMigration(exec boil.Executor, version int64, selectCols ...string) (*SchemaMigration, error)
- func FindSchemaMigrationG(version int64, selectCols ...string) (*SchemaMigration, error)
- func FindSchemaMigrationGP(version int64, selectCols ...string) *SchemaMigration
- func FindSchemaMigrationP(exec boil.Executor, version int64, selectCols ...string) *SchemaMigration
- func (o *SchemaMigration) Delete(exec boil.Executor) error
- func (o *SchemaMigration) DeleteG() error
- func (o *SchemaMigration) DeleteGP()
- func (o *SchemaMigration) DeleteP(exec boil.Executor)
- func (o *SchemaMigration) Insert(exec boil.Executor, whitelist ...string) error
- func (o *SchemaMigration) InsertG(whitelist ...string) error
- func (o *SchemaMigration) InsertGP(whitelist ...string)
- func (o *SchemaMigration) InsertP(exec boil.Executor, whitelist ...string)
- func (o *SchemaMigration) Reload(exec boil.Executor) error
- func (o *SchemaMigration) ReloadG() error
- func (o *SchemaMigration) ReloadGP()
- func (o *SchemaMigration) ReloadP(exec boil.Executor)
- func (o *SchemaMigration) Update(exec boil.Executor, whitelist ...string) error
- func (o *SchemaMigration) UpdateG(whitelist ...string) error
- func (o *SchemaMigration) UpdateGP(whitelist ...string)
- func (o *SchemaMigration) UpdateP(exec boil.Executor, whitelist ...string)
- func (o *SchemaMigration) Upsert(exec boil.Executor, updateOnConflict bool, conflictColumns []string, ...) error
- func (o *SchemaMigration) UpsertG(updateOnConflict bool, conflictColumns []string, updateColumns []string, ...) error
- func (o *SchemaMigration) UpsertGP(updateOnConflict bool, conflictColumns []string, updateColumns []string, ...)
- func (o *SchemaMigration) UpsertP(exec boil.Executor, updateOnConflict bool, conflictColumns []string, ...)
- type SchemaMigrationSlice
- func (o SchemaMigrationSlice) DeleteAll(exec boil.Executor) error
- func (o SchemaMigrationSlice) DeleteAllG() error
- func (o SchemaMigrationSlice) DeleteAllGP()
- func (o SchemaMigrationSlice) DeleteAllP(exec boil.Executor)
- func (o *SchemaMigrationSlice) ReloadAll(exec boil.Executor) error
- func (o *SchemaMigrationSlice) ReloadAllG() error
- func (o *SchemaMigrationSlice) ReloadAllGP()
- func (o *SchemaMigrationSlice) ReloadAllP(exec boil.Executor)
- func (o SchemaMigrationSlice) UpdateAll(exec boil.Executor, cols M) error
- func (o SchemaMigrationSlice) UpdateAllG(cols M) error
- func (o SchemaMigrationSlice) UpdateAllGP(cols M)
- func (o SchemaMigrationSlice) UpdateAllP(exec boil.Executor, cols M)
Constants ¶
This section is empty.
Variables ¶
var ErrSyncFail = errors.New("models: failed to synchronize data after insert")
ErrSyncFail occurs during insert when the record could not be retrieved in order to populate default value information. This usually happens when LastInsertId fails or there was a primary key configuration that was not resolvable.
Functions ¶
func PersonExists ¶
PersonExists checks if the Person row exists.
func PersonExistsG ¶
PersonExistsG checks if the Person row exists.
func PersonExistsGP ¶
PersonExistsGP checks if the Person row exists. Panics on error.
func PersonExistsP ¶
PersonExistsP checks if the Person row exists. Panics on error.
func PetExistsGP ¶
PetExistsGP checks if the Pet row exists. Panics on error.
func PetExistsP ¶
PetExistsP checks if the Pet row exists. Panics on error.
func SchemaMigrationExists ¶
SchemaMigrationExists checks if the SchemaMigration row exists.
func SchemaMigrationExistsG ¶
SchemaMigrationExistsG checks if the SchemaMigration row exists.
func SchemaMigrationExistsGP ¶
SchemaMigrationExistsGP checks if the SchemaMigration row exists. Panics on error.
func SchemaMigrationExistsP ¶
SchemaMigrationExistsP checks if the SchemaMigration row exists. Panics on error.
func SchemaMigrations ¶
SchemaMigrations retrieves all the records using an executor.
func SchemaMigrationsG ¶
SchemaMigrationsG retrieves all records.
Types ¶
type M ¶
type M map[string]interface{}
M type is for providing columns and column values to UpdateAll.
type Person ¶
type Person struct { ID int `boil:"id" json:"id" toml:"id" yaml:"id"` Name null.String `boil:"name" json:"name,omitempty" toml:"name" yaml:"name,omitempty"` R *personR `boil:"-" json:"-" toml:"-" yaml:"-"` L personL `boil:"-" json:"-" toml:"-" yaml:"-"` }
Person is an object representing the database table.
func FindPerson ¶
FindPerson retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.
func FindPersonG ¶
FindPersonG retrieves a single record by ID.
func FindPersonGP ¶
FindPersonGP retrieves a single record by ID, and panics on error.
func FindPersonP ¶
FindPersonP retrieves a single record by ID with an executor, and panics on error.
func (*Person) AddPets ¶
AddPets adds the given related objects to the existing relationships of the person, optionally inserting them as new records. Appends related to o.R.Pets. Sets related.R.Person appropriately.
func (*Person) AddPetsG ¶
AddPetsG adds the given related objects to the existing relationships of the person, optionally inserting them as new records. Appends related to o.R.Pets. Sets related.R.Person appropriately. Uses the global database handle.
func (*Person) AddPetsGP ¶
AddPetsGP adds the given related objects to the existing relationships of the person, optionally inserting them as new records. Appends related to o.R.Pets. Sets related.R.Person appropriately. Uses the global database handle and panics on error.
func (*Person) AddPetsP ¶
AddPetsP adds the given related objects to the existing relationships of the person, optionally inserting them as new records. Appends related to o.R.Pets. Sets related.R.Person appropriately. Panics on error.
func (*Person) Delete ¶
Delete deletes a single Person record with an executor. Delete will match against the primary key column to find the record to delete.
func (*Person) DeleteG ¶
DeleteG deletes a single Person record. DeleteG will match against the primary key column to find the record to delete.
func (*Person) DeleteGP ¶
func (o *Person) DeleteGP()
DeleteGP deletes a single Person record. DeleteGP will match against the primary key column to find the record to delete. Panics on error.
func (*Person) DeleteP ¶
DeleteP deletes a single Person record with an executor. DeleteP will match against the primary key column to find the record to delete. Panics on error.
func (*Person) Insert ¶
Insert a single record using an executor. Whitelist behavior: If a whitelist is provided, only those columns supplied are inserted No whitelist behavior: Without a whitelist, columns are inferred by the following rules: - All columns without a default value are included (i.e. name, age) - All columns with a default, but non-zero are included (i.e. health = 75)
func (*Person) InsertGP ¶
InsertGP a single record, and panics on error. See Insert for whitelist behavior description.
func (*Person) InsertP ¶
InsertP a single record using an executor, and panics on error. See Insert for whitelist behavior description.
func (*Person) Reload ¶
Reload refetches the object from the database using the primary keys with an executor.
func (*Person) ReloadGP ¶
func (o *Person) ReloadGP()
ReloadGP refetches the object from the database and panics on error.
func (*Person) ReloadP ¶
ReloadP refetches the object from the database with an executor. Panics on error.
func (*Person) RemovePets ¶
RemovePets relationships from objects passed in. Removes related items from R.Pets (uses pointer comparison, removal does not keep order) Sets related.R.Person.
func (*Person) RemovePetsG ¶
RemovePetsG relationships from objects passed in. Removes related items from R.Pets (uses pointer comparison, removal does not keep order) Sets related.R.Person. Uses the global database handle.
func (*Person) RemovePetsGP ¶
RemovePetsGP relationships from objects passed in. Removes related items from R.Pets (uses pointer comparison, removal does not keep order) Sets related.R.Person. Uses the global database handle and panics on error.
func (*Person) RemovePetsP ¶
RemovePetsP relationships from objects passed in. Removes related items from R.Pets (uses pointer comparison, removal does not keep order) Sets related.R.Person. Panics on error.
func (*Person) SetPets ¶
SetPets removes all previously related items of the person replacing them completely with the passed in related items, optionally inserting them as new records. Sets o.R.Person's Pets accordingly. Replaces o.R.Pets with related. Sets related.R.Person's Pets accordingly.
func (*Person) SetPetsG ¶
SetPetsG removes all previously related items of the person replacing them completely with the passed in related items, optionally inserting them as new records. Sets o.R.Person's Pets accordingly. Replaces o.R.Pets with related. Sets related.R.Person's Pets accordingly. Uses the global database handle.
func (*Person) SetPetsGP ¶
SetPetsGP removes all previously related items of the person replacing them completely with the passed in related items, optionally inserting them as new records. Sets o.R.Person's Pets accordingly. Replaces o.R.Pets with related. Sets related.R.Person's Pets accordingly. Uses the global database handle and panics on error.
func (*Person) SetPetsP ¶
SetPetsP removes all previously related items of the person replacing them completely with the passed in related items, optionally inserting them as new records. Sets o.R.Person's Pets accordingly. Replaces o.R.Pets with related. Sets related.R.Person's Pets accordingly. Panics on error.
func (*Person) Update ¶
Update uses an executor to update the Person. Whitelist behavior: If a whitelist is provided, only the columns given are updated. No whitelist behavior: Without a whitelist, columns are inferred by the following rules: - All columns are inferred to start with - All primary keys are subtracted from this set Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.
func (*Person) UpdateG ¶
UpdateG a single Person record. See Update for whitelist behavior description.
func (*Person) UpdateGP ¶
UpdateGP a single Person record. UpdateGP takes a whitelist of column names that should be updated. Panics on error. See Update for whitelist behavior description.
func (*Person) UpdateP ¶
UpdateP uses an executor to update the Person, and panics on error. See Update for whitelist behavior description.
func (*Person) Upsert ¶
func (o *Person) Upsert(exec boil.Executor, updateOnConflict bool, conflictColumns []string, updateColumns []string, whitelist ...string) error
Upsert attempts an insert using an executor, and does an update or ignore on conflict.
func (*Person) UpsertG ¶
func (o *Person) UpsertG(updateOnConflict bool, conflictColumns []string, updateColumns []string, whitelist ...string) error
UpsertG attempts an insert, and does an update or ignore on conflict.
type PersonSlice ¶
type PersonSlice []*Person
PersonSlice is an alias for a slice of pointers to Person. This should generally be used opposed to []Person.
func (PersonSlice) DeleteAll ¶
func (o PersonSlice) DeleteAll(exec boil.Executor) error
DeleteAll deletes all rows in the slice, using an executor.
func (PersonSlice) DeleteAllG ¶
func (o PersonSlice) DeleteAllG() error
DeleteAllG deletes all rows in the slice.
func (PersonSlice) DeleteAllGP ¶
func (o PersonSlice) DeleteAllGP()
DeleteAllGP deletes all rows in the slice, and panics on error.
func (PersonSlice) DeleteAllP ¶
func (o PersonSlice) DeleteAllP(exec boil.Executor)
DeleteAllP deletes all rows in the slice, using an executor, and panics on error.
func (*PersonSlice) ReloadAll ¶
func (o *PersonSlice) ReloadAll(exec boil.Executor) error
ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.
func (*PersonSlice) ReloadAllG ¶
func (o *PersonSlice) ReloadAllG() error
ReloadAllG refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.
func (*PersonSlice) ReloadAllGP ¶
func (o *PersonSlice) ReloadAllGP()
ReloadAllGP refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice. Panics on error.
func (*PersonSlice) ReloadAllP ¶
func (o *PersonSlice) ReloadAllP(exec boil.Executor)
ReloadAllP refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice. Panics on error.
func (PersonSlice) UpdateAll ¶
func (o PersonSlice) UpdateAll(exec boil.Executor, cols M) error
UpdateAll updates all rows with the specified column values, using an executor.
func (PersonSlice) UpdateAllG ¶
func (o PersonSlice) UpdateAllG(cols M) error
UpdateAllG updates all rows with the specified column values.
func (PersonSlice) UpdateAllGP ¶
func (o PersonSlice) UpdateAllGP(cols M)
UpdateAllGP updates all rows with the specified column values, and panics on error.
func (PersonSlice) UpdateAllP ¶
func (o PersonSlice) UpdateAllP(exec boil.Executor, cols M)
UpdateAllP updates all rows with the specified column values, and panics on error.
type Pet ¶
type Pet struct { ID int `boil:"id" json:"id" toml:"id" yaml:"id"` Name null.String `boil:"name" json:"name,omitempty" toml:"name" yaml:"name,omitempty"` Kind null.String `boil:"kind" json:"kind,omitempty" toml:"kind" yaml:"kind,omitempty"` PersonID null.Int `boil:"person_id" json:"person_id,omitempty" toml:"person_id" yaml:"person_id,omitempty"` R *petR `boil:"-" json:"-" toml:"-" yaml:"-"` L petL `boil:"-" json:"-" toml:"-" yaml:"-"` }
Pet is an object representing the database table.
func FindPet ¶
FindPet retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.
func (*Pet) Delete ¶
Delete deletes a single Pet record with an executor. Delete will match against the primary key column to find the record to delete.
func (*Pet) DeleteG ¶
DeleteG deletes a single Pet record. DeleteG will match against the primary key column to find the record to delete.
func (*Pet) DeleteGP ¶
func (o *Pet) DeleteGP()
DeleteGP deletes a single Pet record. DeleteGP will match against the primary key column to find the record to delete. Panics on error.
func (*Pet) DeleteP ¶
DeleteP deletes a single Pet record with an executor. DeleteP will match against the primary key column to find the record to delete. Panics on error.
func (*Pet) Insert ¶
Insert a single record using an executor. Whitelist behavior: If a whitelist is provided, only those columns supplied are inserted No whitelist behavior: Without a whitelist, columns are inferred by the following rules: - All columns without a default value are included (i.e. name, age) - All columns with a default, but non-zero are included (i.e. health = 75)
func (*Pet) InsertGP ¶
InsertGP a single record, and panics on error. See Insert for whitelist behavior description.
func (*Pet) InsertP ¶
InsertP a single record using an executor, and panics on error. See Insert for whitelist behavior description.
func (*Pet) Reload ¶
Reload refetches the object from the database using the primary keys with an executor.
func (*Pet) ReloadGP ¶
func (o *Pet) ReloadGP()
ReloadGP refetches the object from the database and panics on error.
func (*Pet) ReloadP ¶
ReloadP refetches the object from the database with an executor. Panics on error.
func (*Pet) RemovePerson ¶
RemovePerson relationship. Sets o.R.Person to nil. Removes o from all passed in related items' relationships struct (Optional).
func (*Pet) RemovePersonG ¶
RemovePersonG relationship. Sets o.R.Person to nil. Removes o from all passed in related items' relationships struct (Optional). Uses the global database handle.
func (*Pet) RemovePersonGP ¶
RemovePersonGP relationship. Sets o.R.Person to nil. Removes o from all passed in related items' relationships struct (Optional). Uses the global database handle and panics on error.
func (*Pet) RemovePersonP ¶
RemovePersonP relationship. Sets o.R.Person to nil. Removes o from all passed in related items' relationships struct (Optional). Panics on error.
func (*Pet) SetPerson ¶
SetPerson of the pet to the related item. Sets o.R.Person to related. Adds o to related.R.Pets.
func (*Pet) SetPersonG ¶
SetPersonG of the pet to the related item. Sets o.R.Person to related. Adds o to related.R.Pets. Uses the global database handle.
func (*Pet) SetPersonGP ¶
SetPersonGP of the pet to the related item. Sets o.R.Person to related. Adds o to related.R.Pets. Uses the global database handle and panics on error.
func (*Pet) SetPersonP ¶
SetPersonP of the pet to the related item. Sets o.R.Person to related. Adds o to related.R.Pets. Panics on error.
func (*Pet) Update ¶
Update uses an executor to update the Pet. Whitelist behavior: If a whitelist is provided, only the columns given are updated. No whitelist behavior: Without a whitelist, columns are inferred by the following rules: - All columns are inferred to start with - All primary keys are subtracted from this set Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.
func (*Pet) UpdateGP ¶
UpdateGP a single Pet record. UpdateGP takes a whitelist of column names that should be updated. Panics on error. See Update for whitelist behavior description.
func (*Pet) UpdateP ¶
UpdateP uses an executor to update the Pet, and panics on error. See Update for whitelist behavior description.
func (*Pet) Upsert ¶
func (o *Pet) Upsert(exec boil.Executor, updateOnConflict bool, conflictColumns []string, updateColumns []string, whitelist ...string) error
Upsert attempts an insert using an executor, and does an update or ignore on conflict.
func (*Pet) UpsertG ¶
func (o *Pet) UpsertG(updateOnConflict bool, conflictColumns []string, updateColumns []string, whitelist ...string) error
UpsertG attempts an insert, and does an update or ignore on conflict.
type PetSlice ¶
type PetSlice []*Pet
PetSlice is an alias for a slice of pointers to Pet. This should generally be used opposed to []Pet.
func (PetSlice) DeleteAllG ¶
DeleteAllG deletes all rows in the slice.
func (PetSlice) DeleteAllGP ¶
func (o PetSlice) DeleteAllGP()
DeleteAllGP deletes all rows in the slice, and panics on error.
func (PetSlice) DeleteAllP ¶
DeleteAllP deletes all rows in the slice, using an executor, and panics on error.
func (*PetSlice) ReloadAll ¶
ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.
func (*PetSlice) ReloadAllG ¶
ReloadAllG refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.
func (*PetSlice) ReloadAllGP ¶
func (o *PetSlice) ReloadAllGP()
ReloadAllGP refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice. Panics on error.
func (*PetSlice) ReloadAllP ¶
ReloadAllP refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice. Panics on error.
func (PetSlice) UpdateAll ¶
UpdateAll updates all rows with the specified column values, using an executor.
func (PetSlice) UpdateAllG ¶
UpdateAllG updates all rows with the specified column values.
func (PetSlice) UpdateAllGP ¶
UpdateAllGP updates all rows with the specified column values, and panics on error.
type SchemaMigration ¶
type SchemaMigration struct { Version int64 `boil:"version" json:"version" toml:"version" yaml:"version"` Dirty bool `boil:"dirty" json:"dirty" toml:"dirty" yaml:"dirty"` R *schemaMigrationR `boil:"-" json:"-" toml:"-" yaml:"-"` L schemaMigrationL `boil:"-" json:"-" toml:"-" yaml:"-"` }
SchemaMigration is an object representing the database table.
func FindSchemaMigration ¶
func FindSchemaMigration(exec boil.Executor, version int64, selectCols ...string) (*SchemaMigration, error)
FindSchemaMigration retrieves a single record by ID with an executor. If selectCols is empty Find will return all columns.
func FindSchemaMigrationG ¶
func FindSchemaMigrationG(version int64, selectCols ...string) (*SchemaMigration, error)
FindSchemaMigrationG retrieves a single record by ID.
func FindSchemaMigrationGP ¶
func FindSchemaMigrationGP(version int64, selectCols ...string) *SchemaMigration
FindSchemaMigrationGP retrieves a single record by ID, and panics on error.
func FindSchemaMigrationP ¶
func FindSchemaMigrationP(exec boil.Executor, version int64, selectCols ...string) *SchemaMigration
FindSchemaMigrationP retrieves a single record by ID with an executor, and panics on error.
func (*SchemaMigration) Delete ¶
func (o *SchemaMigration) Delete(exec boil.Executor) error
Delete deletes a single SchemaMigration record with an executor. Delete will match against the primary key column to find the record to delete.
func (*SchemaMigration) DeleteG ¶
func (o *SchemaMigration) DeleteG() error
DeleteG deletes a single SchemaMigration record. DeleteG will match against the primary key column to find the record to delete.
func (*SchemaMigration) DeleteGP ¶
func (o *SchemaMigration) DeleteGP()
DeleteGP deletes a single SchemaMigration record. DeleteGP will match against the primary key column to find the record to delete. Panics on error.
func (*SchemaMigration) DeleteP ¶
func (o *SchemaMigration) DeleteP(exec boil.Executor)
DeleteP deletes a single SchemaMigration record with an executor. DeleteP will match against the primary key column to find the record to delete. Panics on error.
func (*SchemaMigration) Insert ¶
func (o *SchemaMigration) Insert(exec boil.Executor, whitelist ...string) error
Insert a single record using an executor. Whitelist behavior: If a whitelist is provided, only those columns supplied are inserted No whitelist behavior: Without a whitelist, columns are inferred by the following rules: - All columns without a default value are included (i.e. name, age) - All columns with a default, but non-zero are included (i.e. health = 75)
func (*SchemaMigration) InsertG ¶
func (o *SchemaMigration) InsertG(whitelist ...string) error
InsertG a single record. See Insert for whitelist behavior description.
func (*SchemaMigration) InsertGP ¶
func (o *SchemaMigration) InsertGP(whitelist ...string)
InsertGP a single record, and panics on error. See Insert for whitelist behavior description.
func (*SchemaMigration) InsertP ¶
func (o *SchemaMigration) InsertP(exec boil.Executor, whitelist ...string)
InsertP a single record using an executor, and panics on error. See Insert for whitelist behavior description.
func (*SchemaMigration) Reload ¶
func (o *SchemaMigration) Reload(exec boil.Executor) error
Reload refetches the object from the database using the primary keys with an executor.
func (*SchemaMigration) ReloadG ¶
func (o *SchemaMigration) ReloadG() error
ReloadG refetches the object from the database using the primary keys.
func (*SchemaMigration) ReloadGP ¶
func (o *SchemaMigration) ReloadGP()
ReloadGP refetches the object from the database and panics on error.
func (*SchemaMigration) ReloadP ¶
func (o *SchemaMigration) ReloadP(exec boil.Executor)
ReloadP refetches the object from the database with an executor. Panics on error.
func (*SchemaMigration) Update ¶
func (o *SchemaMigration) Update(exec boil.Executor, whitelist ...string) error
Update uses an executor to update the SchemaMigration. Whitelist behavior: If a whitelist is provided, only the columns given are updated. No whitelist behavior: Without a whitelist, columns are inferred by the following rules: - All columns are inferred to start with - All primary keys are subtracted from this set Update does not automatically update the record in case of default values. Use .Reload() to refresh the records.
func (*SchemaMigration) UpdateG ¶
func (o *SchemaMigration) UpdateG(whitelist ...string) error
UpdateG a single SchemaMigration record. See Update for whitelist behavior description.
func (*SchemaMigration) UpdateGP ¶
func (o *SchemaMigration) UpdateGP(whitelist ...string)
UpdateGP a single SchemaMigration record. UpdateGP takes a whitelist of column names that should be updated. Panics on error. See Update for whitelist behavior description.
func (*SchemaMigration) UpdateP ¶
func (o *SchemaMigration) UpdateP(exec boil.Executor, whitelist ...string)
UpdateP uses an executor to update the SchemaMigration, and panics on error. See Update for whitelist behavior description.
func (*SchemaMigration) Upsert ¶
func (o *SchemaMigration) Upsert(exec boil.Executor, updateOnConflict bool, conflictColumns []string, updateColumns []string, whitelist ...string) error
Upsert attempts an insert using an executor, and does an update or ignore on conflict.
func (*SchemaMigration) UpsertG ¶
func (o *SchemaMigration) UpsertG(updateOnConflict bool, conflictColumns []string, updateColumns []string, whitelist ...string) error
UpsertG attempts an insert, and does an update or ignore on conflict.
type SchemaMigrationSlice ¶
type SchemaMigrationSlice []*SchemaMigration
SchemaMigrationSlice is an alias for a slice of pointers to SchemaMigration. This should generally be used opposed to []SchemaMigration.
func (SchemaMigrationSlice) DeleteAll ¶
func (o SchemaMigrationSlice) DeleteAll(exec boil.Executor) error
DeleteAll deletes all rows in the slice, using an executor.
func (SchemaMigrationSlice) DeleteAllG ¶
func (o SchemaMigrationSlice) DeleteAllG() error
DeleteAllG deletes all rows in the slice.
func (SchemaMigrationSlice) DeleteAllGP ¶
func (o SchemaMigrationSlice) DeleteAllGP()
DeleteAllGP deletes all rows in the slice, and panics on error.
func (SchemaMigrationSlice) DeleteAllP ¶
func (o SchemaMigrationSlice) DeleteAllP(exec boil.Executor)
DeleteAllP deletes all rows in the slice, using an executor, and panics on error.
func (*SchemaMigrationSlice) ReloadAll ¶
func (o *SchemaMigrationSlice) ReloadAll(exec boil.Executor) error
ReloadAll refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.
func (*SchemaMigrationSlice) ReloadAllG ¶
func (o *SchemaMigrationSlice) ReloadAllG() error
ReloadAllG refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice.
func (*SchemaMigrationSlice) ReloadAllGP ¶
func (o *SchemaMigrationSlice) ReloadAllGP()
ReloadAllGP refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice. Panics on error.
func (*SchemaMigrationSlice) ReloadAllP ¶
func (o *SchemaMigrationSlice) ReloadAllP(exec boil.Executor)
ReloadAllP refetches every row with matching primary key column values and overwrites the original object slice with the newly updated slice. Panics on error.
func (SchemaMigrationSlice) UpdateAll ¶
func (o SchemaMigrationSlice) UpdateAll(exec boil.Executor, cols M) error
UpdateAll updates all rows with the specified column values, using an executor.
func (SchemaMigrationSlice) UpdateAllG ¶
func (o SchemaMigrationSlice) UpdateAllG(cols M) error
UpdateAllG updates all rows with the specified column values.
func (SchemaMigrationSlice) UpdateAllGP ¶
func (o SchemaMigrationSlice) UpdateAllGP(cols M)
UpdateAllGP updates all rows with the specified column values, and panics on error.
func (SchemaMigrationSlice) UpdateAllP ¶
func (o SchemaMigrationSlice) UpdateAllP(exec boil.Executor, cols M)
UpdateAllP updates all rows with the specified column values, and panics on error.