fvancrae
(Frederic Vancraeyveldt)
January 10, 2025, 2:15pm
1
We get an exception on a table without a primary key.
We use a custom update and delete command.
No custom insert command.
It looks like an insert is giving us trouble.
Schouldn’t it be possible to insert without a primary key field?
How do we make the code work with the new SDK version?
We are now using RO 10.0.0.1597
mh
(marc hoffman)
January 12, 2025, 2:01pm
2
Go be clear, this used to work before, and is broken/changed in latest, or you never tried/needed his before?
In either rebase, yeah I agree IMHO insert should be allowed w/o a PK (though I dont generally recommend having any data tabes without a PK…)
bugs://D19512 was closed as fixed.
EvgenyK
(Evgeny Karpov)
January 13, 2025, 6:06am
5
Hi,
pls update uDABusinessProcessor.pas
as
function TDABusinessProcessor.GenerateSQL2(aChangeType: TDAChangeType;
...
lUpdateMode := fUpdateMode;
DAError((aChangeType <> ctInsert) and (aDelta.KeyFieldCount = 0) and (lUpdateMode = updWhereKeyOnly), err_updWhereKeyOnly_noPK); //<<< changed
lPKList := TStringList.Create;
launch C:\Program Files (x86)\RemObjects Software\Build\install_DA.cmd
with admin rights for rebuilding .dcu and .bpl
fvancrae
(Frederic Vancraeyveldt)
January 13, 2025, 7:33am
6
Yes, our code hasn’t changed. It’s a result of a change in RO/DA
Thanks for the quick fix
1 Like