Support for 'update .. returning ..' syntax

Issue #797 resolved
Former user created an issue

(original reporter: ants) PostgreSQL supports returning the changed rows from an update statement. The syntax is ''regular_update_clause + ' RETURNING ' + column_list'', where column_list has the exact same syntax as the one in a select clause.

To support this it would be necessary to: 1. Support adding a column list to an update clause by either adding it to a regular Update class or subclassing it for Postgres. 2. Make the compiler support it. 3. Make the ExecutionContext properly recognize it as a select. Changing the regexp to r'\s(?:SELECT|FETCH|UPDATE.RETURNING)' would work most of the time, but it should check that the RETURNING keyword isn't quoted.

Comments (1)

  1. Log in to comment