Posted By: KAndrew CachedUpdates without ROWID - 09/22/03 11:45 PM
I copy this topic from the DOA Beta forum.

posted 12 September 2003 16:31
--------------------------------------------------------------------------------
Hello Marco!
Are You planning release the CachedUpdates based on TOracleDataSet.UniqueFields? The ROWID is not suitable for any needs, e.g. updates Views with instead of triggers.
-----------------------------------
Andrew.


posted 18 September 2003 15:21
--------------------------------------------------------------------------------
For views with instead of triggers you can still obtain a rowid. You must set the UniqueFields though.
------------------
Marco Kalter
Allround Automations

posted 18 September 2003 18:27
--------------------------------------------------------------------------------
Hi!
If view has DISTINCT, GROUP BY, UNION clause and join several tables all update logic release in instead of trigger, so ROWID cached updates works only with one updating table. I must specify UpdatingTable for CashedUpdates and DOA produce this statements:
DOA DMLQuery

1) select * from UpdatingTable where rowid = :doa__rowid
2) savepoint DOA_APPLYPOINT
3) select * from UpdatingTable where rowid = :doa__rowid for update nowait
4) update UpdatingTable set FieldName = :FieldName where rowid = :doa__rowid
5) commit;


If UpdatingTable is complex view then Oracle raise ORA-01446.

If UpdatingTable is one of the view's table,
I can update only one, instead of triggers not fired.

With unique fields

select * from UpdatingTable where UniqueFieldName1 = :UniqueFieldName1
[and
UniqueFieldName2 = :UniqueFieldName2
..]
and so on..

This statements solve the problem.
This would be a great feature!
--------------------------------------
Regards,
Andrew.
Posted By: KAndrew Re: CachedUpdates without ROWID - 09/23/03 03:07 PM
Hello Marco!

I think, It's nessesary to introduce new property (UpdateKind ?) in the TOracleDataset, which determinate what kind of updates to use: ROWID or UniqueFields. There are no any difficulties to implement "UniqueFields" updates. I'm glad to help you.

---------------------------------------------
Regards,
Andrew.
Posted By: Marco Kalter Re: CachedUpdates without ROWID - 09/23/03 08:42 PM
This is indeed not terribly difficult. We'll consider it.

------------------
Marco Kalter
Allround Automations
Posted By: Matt Ors Re: CachedUpdates without ROWID - 06/06/19 01:51 PM
Any news on this feature?

Best Regards
Matt
© Allround Automations forums