View Source AshPostgres.DataLayer.Info (ash_postgres v2.4.16)
Introspection functions for
Summary
Functions
A stringified version of the base_filter, to be used in a where clause when generating unique indexes
A keyword list of calculations to their sql representation
The configured check_constraints for a resource
The configured custom_indexes for a resource
The configured custom_statements for a resource
The configured exclusion_constraint_names
The configured foreign_key_names
A list of keys to always include in upserts.
The configured identity_index_names
Returns the literal SQL for the where
clause given a resource and an
identity name.
A keyword list of identity names to the literal SQL string representation of
the where
clause portion of identity's partial unique index.
Whether or not to create a tenant for a given resource
The template for a managed tenant
Whether or not to update a tenant for a given resource
Whether or not the resource should be included when generating migrations
A keyword list of customized migration defaults
A list of attributes to be ignored when generating migrations
A keyword list of customized migration types
Gets the resource's repo's postgres version
Checks a version requirement against the resource's repo's postgres version
The configured polymorphic? for a resource
The configured polymorphic_reference_name for a resource
The configured polymorphic_reference_on_delete for a resource
The configured polymorphic_reference_on_update for a resource
The configured reference for a given relationship of a resource
The configured references for a resource
The configured repo for a resource
The configured schema for a resource
Identities not to include in the migrations
Skip generating unique indexes when generating migrations
A keyword list of customized storage types
The configured table for a resource
The configured unique_index_names
Functions
A stringified version of the base_filter, to be used in a where clause when generating unique indexes
A keyword list of calculations to their sql representation
The configured check_constraints for a resource
The configured custom_indexes for a resource
The configured custom_statements for a resource
The configured exclusion_constraint_names
The configured foreign_key_names
A list of keys to always include in upserts.
The configured identity_index_names
@spec identity_where_to_sql(Ash.Resource.t(), atom()) :: String.t() | nil
Returns the literal SQL for the where
clause given a resource and an
identity name.
See identity_wheres_to_sql/1
for more details.
@spec identity_wheres_to_sql(Ash.Resource.t()) :: keyword(String.t())
A keyword list of identity names to the literal SQL string representation of
the where
clause portion of identity's partial unique index.
For example, given the following identity for a resource:
identities do
identity :active, [:status] do
where expr(status == "active")
end
end
An appropriate identity_wheres_to_sql
would need to be made to generate the
correct migration for the partial index used by the identity:
postgres do
...
identity_wheres_to_sql active: "status = 'active'"
end
Whether or not to create a tenant for a given resource
The template for a managed tenant
Whether or not to update a tenant for a given resource
Whether or not the resource should be included when generating migrations
A keyword list of customized migration defaults
A list of attributes to be ignored when generating migrations
A keyword list of customized migration types
Gets the resource's repo's postgres version
Checks a version requirement against the resource's repo's postgres version
The configured polymorphic? for a resource
The configured polymorphic_reference_name for a resource
The configured polymorphic_reference_on_delete for a resource
The configured polymorphic_reference_on_update for a resource
The configured reference for a given relationship of a resource
The configured references for a resource
The configured repo for a resource
The configured schema for a resource
Identities not to include in the migrations
Skip generating unique indexes when generating migrations
A keyword list of customized storage types
The configured table for a resource
The configured unique_index_names