Enhancements
- Add functionality for constraint checking in the storage to
Ecto.Changeset
. Support was added forunique_constraint/3
(powered by unique indexes) andforeign_key_constraint/3
,assoc_constraint/3
(belongs to) andno_assoc_constraint/3
(has one/many) - Support empty lists as default values
- Support changing/setting null and default on
modify/3
in migrations
Bug fixes
- Do not generate changes when parameters are
:empty
even for embeds/associations - Raise on bad options in
validate_number/3
get_field/3
andfetch_field/2
for relations return models- Ensure NULL and DEFAULT are respected when defining references
Deprecations
Ecto.Changeset.validate_unique/3
is deprecate in favor ofEcto.Changeset.unique_constraint/3
. Read the documentation for the latter for more information on updating
Backwards incompatible changes
Ecto.Adapters.SQL.query/4
now returns{:ok, result}
. UseEcto.Adapters.SQL.query!/4
for the previous behaviour
Adapter backwards incompatible changes
- Receive context on
Ecto.Adapter.insert/update/delete
. Expect context on schema load.