study_gorm

package
v0.0.0-...-66b0031 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 17, 2020 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateAnimals

func CreateAnimals(db *gorm.DB) error

func ExampleCreate

func ExampleCreate(db *gorm.DB)

func ExampleDelete

func ExampleDelete(db *gorm.DB)

func ExampleQuery

func ExampleQuery(db *gorm.DB)

func ExampleUpdate

func ExampleUpdate(db *gorm.DB)

Types

type Animal

type Animal struct {
	ID      int64
	Name    string        `gorm:"default:'galeone'"`
	Age     sql.NullInt32 `gorm:"default:18"`
	OwnerId int64
}

type Owner

type Owner struct {
	ID   int64
	Name string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL