# I need to load my MySQl tables with data from Excel

**URL:** <https://forum.inductiveautomation.com/t/i-need-to-load-my-mysql-tables-with-data-from-excel/261>\
**Category:** Archived Topics\
**Created:** [April 23, 2007, 9:01pm UTC](https://forum.inductiveautomation.com/t/i-need-to-load-my-mysql-tables-with-data-from-excel/261 "2007-04-23T21:01:05Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![DB2](https://avatars.discourse-cdn.com/v4/letter/d/e0b2c6/32.png) [@DB2](https://forum.inductiveautomation.com/u/DB2)\
**Post date:** [April 23, 2007, 9:01pm UTC](https://forum.inductiveautomation.com/t/i-need-to-load-my-mysql-tables-with-data-from-excel/261/1 "2007-04-23T21:01:05Z")

</div>

Will the before mentioned solution work in both directions, I only need to send data from Excel to MySQl.

---

<div class="post-metadata">

**Author:** ![Colby.Clegg](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/colby.clegg/32/3282_2.png) [@Colby.Clegg](https://forum.inductiveautomation.com/u/Colby.Clegg)\
**Post date:** [April 23, 2007, 10:12pm UTC](https://forum.inductiveautomation.com/t/i-need-to-load-my-mysql-tables-with-data-from-excel/261/2 "2007-04-23T22:12:00Z")

</div>

Is this a simple CSV or a more complicated excel file? Straightforward CSV input into mysql isn’t too tough, and can be accomplished with something like:

`LOAD DATA LOCAL INFILE '/importfile.csv'
INTO TABLE test_table
FIELDS TERMINATED BY ','
LINES TERMINATED BY '\n'
(field1, filed2, field3);`

But if your excel file is too complicated to be exported to simple CSV first, I’m not quite sure yet…

Regards,

---

<div class="post-metadata">

**Author:** ![nathan](https://avatars.discourse-cdn.com/v4/letter/n/c5a1d2/32.png) [@nathan](https://forum.inductiveautomation.com/u/nathan)\
**Post date:** [April 23, 2007, 10:22pm UTC](https://forum.inductiveautomation.com/t/i-need-to-load-my-mysql-tables-with-data-from-excel/261/3 "2007-04-23T22:22:35Z")

</div>

Colby’s MySQL script is a way of creating/writing to a MySQL database from a spreadsheet/CSV file. Based on his other post, I think he wants to use Excel as a DB frontend. It is capable of reading from, but not writing to the database in a linked manner. I described how you can use MS Access as an SQL database frontend with linked tables in response to your other post.

[inductiveautomation.com/foru … php?p=3079](http://www.inductiveautomation.com/forum/viewtopic.php?p=3079)
