Writing a large table to disk

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
bubs75
Posts: 4
Joined: Mon 08 Jun 2009 16:16

Writing a large table to disk

Post by bubs75 » Thu 18 Jun 2009 15:57

I am trying to export data from a database via a query.

Unfortunately the table I am trying to export is large ( > 3 GB ) and consequently I get an out of memory error.

The data is retrieved on a seperate thread.

Is it possible to free the data written to file?
And could I check the size of the data already retrieved?

That way I could pause the thread and wait for some of the data to be written to file before continuing.

Dimon
Devart Team
Posts: 2885
Joined: Mon 05 Mar 2007 16:32

Post by Dimon » Fri 19 Jun 2009 09:54

Try to use the TMSDump component to export data from a database.
TMSDump serves to store data from tables or editable views as a script and to restore data from a received script.

bubs75
Posts: 4
Joined: Mon 08 Jun 2009 16:16

Post by bubs75 » Fri 19 Jun 2009 13:06

Can't use the TMSDump component since I need to write out in a specific format.

However reviewing the TMSDump backup method pointed me in the right direction.

I've taken the query off the thread and set UniDirectional to True. The help file pointed out this turns caching off.

Dimon
Devart Team
Posts: 2885
Joined: Mon 05 Mar 2007 16:32

Post by Dimon » Mon 22 Jun 2009 07:40

It is good to see that this problem has been solved. If any other questions come up, please contact me.

Post Reply