API Reference ash_postgres v1.3.28
modules
Modules
The AshPostgres extension gives you tools to map a resource to a postgres database table.
A custom aggregate implementation for ecto.
A postgres data layer that leverages Ecto's postgres capabilities.
Introspection functions for
A function that maps to ecto's fragment
function
Maps to the builtin postgres function ilike
.
Maps to the builtin postgres function like
.
Maps to the builtin postgres trigram similarity function. Requires pgtrgm
extension to be installed.
A behavior for postgres-specific manual relationship functionality
Utilities for use in migrations
Resources that use AshPostgres.DataLayer
use a Repo
to access the database.
Ensures that there is a table configured or the resource is polymorphic
Prevents at compile time certain aggregates that are unsupported by AshPostgres
Ensures that all references
on a resource refer to a real relationship
Verifies that the repo is configured correctly
Allows configuring how values are translated to default values in migrations.
mix-tasks
Mix Tasks
Create the storage for repos in all resources for the given (or configured) apis.
Drop the storage for the given repository.
Generates migrations, and stores a snapshot of your resources.
Runs the pending migrations for the given repository.
Reverts applied migrations in the given repository.
Migrations are expected at "priv/YOUR_REPO/migrations" directory
of the current application but it can be configured by specifying
the :priv
key under the repository configuration.
Runs the latest applied migration by default. To roll back to
a version number, supply --to version_number
. To roll back a
specific number of times, use --step n
. To undo all applied
migrations, provide --all
.