On 2/17/24 07:24, Karsten Hilbert wrote:
Dear list members,


So, is this doable within one SQL statement (short of
creating and running the abovementioned function in
one go ;-) ?

Don't know what version of Postgres you are on, assuming 15+ then maybe?:

MERGE

https://www.postgresql.org/docs/current/sql-merge.html



(the real story is about medication and intake regimens /
schedules thereof involving a whole lot more columns, of
course, which should not be relevant to the problem though)

Thanks for taking the time to read,
Karsten
--
GPG  40BE 5B0E C98E 1713 AFA6  5BC0 3BEA AC80 7D4F C89B



--
Adrian Klaver
adrian.kla...@aklaver.com



Reply via email to