Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2004

    Unanswered: 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

  2. #2
    Join Date
    Feb 2004
    In front of the computer
    Provided Answers: 54
    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.


  3. #3
    Join Date
    Apr 2004

    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.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts