BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

TClientDataSet and range

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (SQL Servers)
View previous topic :: View next topic  
Author Message
donlelel
Guest





PostPosted: Tue Jul 19, 2005 2:01 pm    Post subject: TClientDataSet and range Reply with quote



Hi,

I'm working on a db project to convert it from using FlashFiler to
using MySql. The components I'm using to access MySql are from the
MySqlDac library.

The way things worked before :
- TClientDataSet (cds) linked to TDataSetProvider (prov) linked to
TffTable (tb)
- retrieving only the recs pertaining to a given customer was done by
something like this :
1. cds.Close;
2. ApplyRangeOnFFTable(tb,Fld_IdClient,[fIdClient],[fIdClient]);
// i.e. tb.IndexName:=aIdxName;if not tb.Active then
tb.Active:=True;tb.SetRange ...
3. cds.Open;

Now, trying the same thing with MySqlDac table component (ntb), the cds
contains all the recs from the table and not only the ones needed.
Adding the same range on the cds helps in retrieving only the good
recs, but it just takes too long. The problem is that cds.Open with ntb
just cancels the existing range on the ntb. Is there a simpler way to
just get the recs (that are already retrieved) from ntb in cds without
any more querying the MySql server? I mean, well, the ntb has new data,
have cds refresh its content from the ntb only.

Thanks,Don

Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (SQL Servers) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.