migrant/database
Types
pub type QueryResult(a) =
Result(List(a), types.Error)
Values
pub fn apply_migrations(
db: sqlight.Connection,
migrations: dict.Dict(String, types.Migration),
) -> Result(Nil, types.Error)
pub fn create_migrations_table(
db: sqlight.Connection,
next: fn() -> Result(Nil, types.Error),
) -> Result(Nil, types.Error)
pub fn exec(
db: sqlight.Connection,
sql: String,
) -> Result(Nil, types.Error)
pub fn filter_applied_migrations(
db: sqlight.Connection,
migrations: dict.Dict(String, types.Migration),
next: fn(dict.Dict(String, types.Migration)) -> Result(
Nil,
types.Error,
),
) -> Result(Nil, types.Error)
pub fn query(
db: sqlight.Connection,
query sql: String,
args args: List(sqlight.Value),
decoder decoder: decode.Decoder(a),
) -> Result(List(a), types.Error)