Documentation
¶
Index ¶
- func AdvancedQueryExample(db interface{})
- func BatchUpsertExample(db interface{})
- func ComparisonExample()
- func CreateUserBadExample(db interface{})
- func CreateUserExample(db interface{})
- func DeleteUserExample(db interface{})
- func ExampleSimpleCRUD()
- func PerformanceExample(db interface{})
- func QueryUserExample(db interface{})
- func RealWorldExample()
- func TransactionExample(db interface{})
- func UpdateUserExample(db interface{})
- func UsageGuide()
- type UserExample
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BatchUpsertExample ¶
func BatchUpsertExample(db interface{})
BatchUpsertExample 批量Upsert - 推荐写法
func CreateUserBadExample ¶
func CreateUserBadExample(db interface{})
CreateUserBadExample 创建用户 - 不推荐写法
Types ¶
type UserExample ¶
type UserExample struct {
ID int64 `json:"id"`
Name string `json:"name"`
Email string `json:"email"`
Age int `json:"age"`
Status string `json:"status"`
Version int64 `json:"version"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
DeletedAt *time.Time `json:"deleted_at,omitempty"`
}
UserExample 用户示例
Click to show internal directories.
Click to hide internal directories.