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 

Slow performance with TADOTable.Post

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (ADO)
View previous topic :: View next topic  
Author Message
Gabriel Ballesteros
Guest





PostPosted: Tue Feb 24, 2004 5:14 pm    Post subject: Slow performance with TADOTable.Post Reply with quote



Hello,

I'm developing any application with Delphi5 and MySQL 4,0,15 maxdebug. I'm
use MySQL ODCB 3.51.06 with ADO components to connect MySQL .

I have the following piece of code :

AdoTable1.Open;
while not AdoTable1.Eof do
begin
AdoTable1.Edit;

AdoTable1.FieldByName('salary').AsFloat:=Table1.FieldByName('salary').AsFloa
t *
1.5;
AdoTable1.Post; // Here exists slow performance.
AdoTable1.Next;
end;
AdoTable1.Close;

The problem is that when invoking the edit and post methods the application
present slow peformance.

The same piece of code using TTable(BDE) executing with high performance.

The table having 3000 records and having defined primary key in the
indexname property.

Excuse me for my English.

Gabriel Ballesteros
Medellín - Colombia



Back to top
Gabriel Ballesteros
Guest





PostPosted: Thu Feb 26, 2004 4:43 pm    Post subject: Re: Slow performance with TADOTable.Post Reply with quote



I try with the method disablecontrols but the performance continues being
the same one

"Brian Bushay TeamB" <BBushay (AT) Nmpls (DOT) com> escribió en el mensaje
news:i5vn30tsifkgufeg1cb2kerskgs20odnv2 (AT) 4ax (DOT) com...
Quote:

while not AdoTable1.Eof do
begin
AdoTable1.Edit;


AdoTable1.FieldByName('salary').AsFloat:=Table1.FieldByName('salary').AsFlo
a
t *
1.5;
AdoTable1.Post; // Here exists slow performance.
AdoTable1.Next;
end;

You will pickup some speed using disblecontrols

with AdoTable1 do Try
disableControls;
Open;
while not Eof do begin
Edit;
FieldByName('salary').AsFloat:=Table1.FieldByName('salary').AsFloat
*1.5;
Post; // Here exists slow performance.
Next;
end;//while
Close;
finally
EnableControls
end;//try

--
Brian Bushay (TeamB)
[email]Bbushay (AT) NMPLS (DOT) com[/email]



Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (ADO) 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.