Re: [sqlalchemy] FetchedValue columns are INSERTed by Session.merge()

2020-10-02 Thread Mike Bayer
On Fri, Oct 2, 2020, at 12:15 PM, Wilson, Chris wrote: > Dear Michael and co, > > I think that Columns which are marked as server_default=FetchedValue(), which > are normally omitted from INSERT statements, are not omitted after an object > has been merged from another session. Therefore

[sqlalchemy] FetchedValue columns are INSERTed by Session.merge()

2020-10-02 Thread Wilson, Chris
Dear Michael and co, I think that Columns which are marked as server_default=FetchedValue(), which are normally omitted from INSERT statements, are not omitted after an object has been merged from another session. Therefore SQLAlchemy tries to assign the old values to them, which fails if the