github elixir-ecto/ecto v0.7.0

latest releases: v3.11.2, v3.11.1, v3.11.0...
9 years ago

Enhancements

  • Provide Ecto.Adapters.SQL with implementation to be shared by SQL adapters
  • Allow disctinct: selector in query syntax
  • Support has_many :through and has_one :through associations. :through can nest any type of association through n-levels
  • Provide type/2 in query syntax for explicitly casting any external value
  • Add Ecto.UUID type that handles UUIDs as strings
  • Add casting support to Ecto.DateTime and related types
  • Allow a map with atom keys or a map with string keys in Ecto.Changeset.cast/4

Bug fixes

  • Fix a limitation where only one nameless join could be given to a query
  • Ensure duplicated preloads are loaded only once
  • Ensure p.field in select returns the proper field type

Backwards incompatible changes

  • Ecto.Adapters.Postgres.query/4 has been renamed to Ecto.Adapters.SQL.query/4
  • Ecto.Adapters.Postgres.begin_test_transaction/2 has been renamed to Ecto.Adapters.SQL.begin_test_transaction/2
  • Ecto.Adapters.Postgres.rollback_test_transaction/2 has been renamed to Ecto.Adapters.SQL.rollback_test_transaction/2
  • Mix tasks now expect the repository with the option -r, otherwise it defaults to the application based one
  • :datetime, :time and :date will now return tuples in Ecto queries. To keep the previous behaviour, please replace the types in your schema with Ecto.DateTime, Ecto.Time and Ecto.Date
  • Ecto.Changeset.validate_change/4 now passes the field and value to the callback function instead of only the value

Don't miss a new ecto release

NewReleases is sending notifications on new releases.