You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wanted to use MyApp.Repo.stream to upgrade some rows in my tables to a format with new constraints (in this case: Giving all of them a UUID, since all newly-inserted models will have this UUID).
So MyApp.Repo.stream will raise an error, stating that EctoMnesia.Table.Stream.new should be used instead.
However:
This does not support queries, but only low-level table names.
This gives results in record-format, rather than as schema structs. AFAIK, there is no way that EctoMnesia exposes turning records to schema structs. I ended up performing an additional MyRepo.get!(NameOfModel, elem(record, 1)), but this is obviously a non-performant and hackish 'solution'.
The text was updated successfully, but these errors were encountered:
I wanted to use
MyApp.Repo.stream
to upgrade some rows in my tables to a format with new constraints (in this case: Giving all of them a UUID, since all newly-inserted models will have this UUID).So
MyApp.Repo.stream
will raise an error, stating thatEctoMnesia.Table.Stream.new
should be used instead.However:
MyRepo.get!(NameOfModel, elem(record, 1))
, but this is obviously a non-performant and hackish 'solution'.The text was updated successfully, but these errors were encountered: