%Postgrex.Interval{}
for the new :duration
column type fails to load
#706
Labels
%Postgrex.Interval{}
for the new :duration
column type fails to load
#706
Elixir version
1.17.2
Database and Version
15.6
Postgrex Version
Current behavior
After adding a column with the following migration:
add(:duration, :duration, default: fragment("interval '1 day'"), null: false)
To a schema declared with:
field(:duration, :duration, default: Duration.new!(day: 1))
Running a test that inserts an entry,
ecto
fails to return a result, raising the following error:Expected behavior
Since the value is correctly persisted to PostgreSQL, it should've also been loaded. It seems some mapping is missing.
Related to elixir-ecto/ecto_sql#631 and #688
The text was updated successfully, but these errors were encountered: