Re: [sqlalchemy] Re: How to add the index_elements to the on_conflict_do_update() method

2021-12-08 Thread Simon King
Does the table definition in postgres match your SQLAlchemy definition? Adding "unique=True" to the SQLAlchemy table definition will not automatically add an index to an existing table in the database. If you connect to the database using "psql" and run "\d message_symbol", does it show the

[sqlalchemy] Re: How to add the index_elements to the on_conflict_do_update() method

2021-12-07 Thread Chaozy Z
I also tried to add unique=True to the column message_id but still fail with the same error On Tuesday, 7 December 2021 at 22:21:49 UTC Chaozy Z wrote: > Hi there, I just started to learn SQLAlchemy. 0 > > > I have a `on_conflict_do_update`