TClientdataSet.locate on TUniQuery fail
Posted: Thu 18 Jun 2015 16:54
Hello,
Im migrating my application from ADO (D7, TADOquery -> TDatasetProvider -> TClientdataset) to UNIDAC component (both Oracle or SQLServer Provider).
I make a simple locate() on the clientDataset. This one worked fine before, but not now with UniDac. I do not understand at all what I've done!! This is a very simple test case!
Here is the code:
Does someone have experience something like this or can point me on the way to find a solution?
I cannot continue my migration to Unidac instead of making this behavior out.
Regards
Im migrating my application from ADO (D7, TADOquery -> TDatasetProvider -> TClientdataset) to UNIDAC component (both Oracle or SQLServer Provider).
I make a simple locate() on the clientDataset. This one worked fine before, but not now with UniDac. I do not understand at all what I've done!! This is a very simple test case!
Here is the code:
Code: Select all
uniquery1.close;
uniquery1.ParamByName('NumFol').Value := 17;
uniquery1.ParamByName('Codpro').Value := 'AD';
uniquery1.ParamByName('Coduti').Value := 'MR';
uniquery1.open; //just to prepare and get the data (->single row)
ClientDataSet1.open;
ClientDataSet1.Locate('ID_NUMFOL;NU_TYPE;ST_DES',varArrayOF(['17',1,'BUS - BT + Détails et Coûts']),[loCaseInsensitive]); //EDataBaseError on DB.pas - "the constant is not of type 17 correct"
Code: Select all
ADOQuery1.close;
ADOQuery1.Parameters.ParamByName('NumFol').Value := 17;
ADOQuery1.Parameters.ParamByName('Codpro').Value := 'AD';
ADOQuery1.Parameters.ParamByName('Coduti').Value := 'MR';
ADOQuery1.open; //same query, same database (oracle)
ClientDataSet2.open;
ClientDataSet2.Locate('ID_NUMFOL;NU_TYPE;ST_DES',varArrayOF(['17',1,'BUS - BT + Détails et Coûts']),[loCaseInsensitive]); //works perfectly
I cannot continue my migration to Unidac instead of making this behavior out.

Regards