db

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 11, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Migrate

func Migrate(ctx context.Context, database *sql.DB) error

Migrate 按文件名中的版本号顺序执行迁移,成功后在同一事务中记账。

func Open

func Open(ctx context.Context, path string) (*sql.DB, error)

Open 配置单连接,保证每次访问都启用连接级外键约束。

Types

This section is empty.

Jump to

Keyboard shortcuts

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