If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > Delphi, C etc > Exporting data from mysql

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 07-09-04, 06:36
m.inckle m.inckle is offline
Registered User
 
Join Date: Feb 2004
Posts: 24
Exporting data from mysql

I dont know if this is a mysql or delphi question

How can i programmatically export a table from mysql into a csv

I'm using mysql 4.0.1 and programing in delphi 5
Reply With Quote
  #2 (permalink)  
Old 07-09-04, 08:50
Pat Phelan Pat Phelan is offline
Resident Curmudgeon
 
Join Date: Feb 2004
Location: In front of the computer
Posts: 12,605
If I were doing this, I'd probably create a Delphi object to do a table to CSV translation. This puts a bit more load on the network, the bulk of the load on the client, but significantly less load on the MySQL server. It also allows for the greatest scalability.

If XML is good enough, you could use MySQLDUMP. This is a lot easier to write, and it keeps the network load light, but it puts the bulk of the load on the MySQL Server. To get simplicity, you trade scalability.

There are probably lots of other solutions, but these are what jump right to my mind. You might consider posting this question in the MySQL forum to see what suggestions they can offer.

-PatP
Reply With Quote
  #3 (permalink)  
Old 07-09-04, 10:49
AceOmega AceOmega is offline
Registered User
 
Join Date: Apr 2004
Location: Arizona
Posts: 49
Little of Both

You could do a little of both. If you make stored procedures to format the data and use a delphi program as your data pump to establish a connection you could spread some of the work load to the server.

As was mentioned above, you could use the data pump that comes with MySQL but be wanred, data pumps dod not always format the data properly and there are some times problems between Extended SQL field types. When we went from Paradox and Informix to Interbase we did some research into the most standard types and made sure that we setup a scema that would use them. This made it alot easyer to use the data pump programs out there.

I hope this is what you are looking for.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On