Open wpichler opened 1 year ago
Thanks for the pull request.
As you mentioned above, RETURNING clause might be working in MariaDB >10.5 but not in MySQL. So the changes will be complicated even if we try to implement only for MariaDB as mysql_fdw supports both. Currently, this is not on our roadmap but if you have a working patch ready for the same, we will be happy to review and take it further. From the pull request that you submitted, I can see code changes but I don't think those are considered for MySQL as well.
The current PR is just a starting point - far from complete. For the real implementation i would implement a query to get the server type (mysql / mariadb) and version. And depending on the version the returning is then available or not.
@wpichler , there is version functions and full RETURNING
support in firebird_fdw. You can read the interesting realisation from @ibarwick.
Hi all,
MariaDB > 10.5 does support RETURNING now.
https://mariadb.com/kb/en/insertreturning/
I'd like to add this feature to mysql_fdw - but without knowing the fdw sources / postgres internals it is hard to handle.
This is Work in Progress - maybe someone has already done this - also working on it ?
Currently i do get a cache lookup error on the columns translate - i think i am using it not correct.