Hello,
Have a timestamp for record created, one for record changed, a field created by default user name and need another one for record changed by.
The normal sql syntax UPDATE "tblxxx" SET "yyyy" = "zzz" needs a WHERE clause so that only the selected record is updated. There does not seem to be a record number property and according to the HSQL man the rownum() can not be used for = or > condition.
Anyone done something similar ?
Thks
[Solved] SQL How to update current row
[Solved] SQL How to update current row
Last edited by gkick on Tue Nov 26, 2019 10:03 pm, edited 1 time in total.
Libre Office 6.4.6 on Windows 10 HSQL 2.51 backend
Re: SQL How to update current row
Your table should have a primary key to identify a distinct record.
Please, edit this topic's initial post and add "[Solved]" to the subject line if your problem has been solved.
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Ubuntu 18.04 with LibreOffice 6.0, latest OpenOffice and LibreOffice
Re: SQL How to update current row
Ahh, thanks that's it, store the pk to a variable and use it in the where clause, thanks !!!
Libre Office 6.4.6 on Windows 10 HSQL 2.51 backend