MyQuery.Append

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
siik
Posts: 10
Joined: Fri 12 Jun 2009 06:10

MyQuery.Append

Post by siik » Fri 16 Oct 2009 04:45

Hi,

Im not sure if anyone else has the same issue but here goes...


I have a number of tables where the bulk of data transactions are appends.
To do this i use a TMyQuery. First i enter the SQL: 'Select * from '.
Then i call the TMyQuery.Append procedure and proceed to populate fields using TMYquery.Fields[0].AsString etc.

I understand that the select statement before the append statement is fetching the whole dataset, so i would like to avoid this (uneccessary network/server utilization).

Is there a way to.... instead of 'select *' to maybe 'Use ' before the append call?

Cheers

Challenger
Devart Team
Posts: 925
Joined: Thu 17 Nov 2005 10:53

Post by Challenger » Fri 16 Oct 2009 10:58

You can write something like select * from where 0 = 1.

siik
Posts: 10
Joined: Fri 12 Jun 2009 06:10

Post by siik » Fri 23 Oct 2009 09:09

Cheers,

Probably should have thought of that myself!!!

:)

Post Reply