Since the id column created by default by Ecto is not an integer but a bigint, it should be the same way in the example to prevent confusion and problems.
The field definition in the schema itself should still be integer, only the migration type is changed.
Since the
id
column created by default by Ecto is not aninteger
but abigint
, it should be the same way in the example to prevent confusion and problems.The
field
definition in the schema itself should still beinteger
, only the migration type is changed.