TUniQuery, Clone with datas
Posted: Mon 21 Feb 2011 09:00
Hello together,
sometimes I need two instances of a DB. With ADO I made a ADODataset.clone. In Uniquery I can make
But the open needs again 18 seconds. Is there a faster way to get a clone from UniQuery1 for example after an insert in UniQuery1?
The long time (18s) is coming from setting the IndexFieldNames to make shure the datas are also sortetd correct after an insert.
Sometimes I need in UniQuery2 only some columns of the table. But UniQuery2 should also be updatetd in a fast way after an insert in UniQuery1. How to do this?
I also tried
but this needs longer than an assign with following open
best thanks
Gerd
sometimes I need two instances of a DB. With ADO I made a ADODataset.clone. In Uniquery I can make
Code: Select all
UniQuery2.Assign(UniQuery1);
UniQuery2.Open;The long time (18s) is coming from setting the IndexFieldNames to make shure the datas are also sortetd correct after an insert.
Sometimes I need in UniQuery2 only some columns of the table. But UniQuery2 should also be updatetd in a fast way after an insert in UniQuery1. How to do this?
I also tried
Code: Select all
CRBatchMove1.Destination:=VirtualTable1;
CRBatchMove1.Source:=UniQuery1;
CRBatchMove1.mode:=bmAppend;
VirtualTable1.FieldDefs := UniQuery1.FieldDefs;
CRBatchMove1.Execute;
if not VirtualTable1.Active then
VirtualTable1.Open;best thanks
Gerd