views:

19

answers:

1

I have a spreadsheet that is currently formatted improperly for a mysql import. The data are organized by column rather than by row. So, the first column has the field names, the second column contains record 1, and so on.

Is it possible for mysql to understand this data? If not, any ideas on how to import these data besides redoing the spreadsheet?

The data are currently in a google doc.

Edit: I write php, if that helps the matter at all, though I was planning on importing using sequel pro.

+2  A: 

You tagged this "import-from-excel"; you could simply select the data in excel, copy, and then use "paste special" to transpose the data (it's a checkbox near the bottom of the "paste special" window; see image).

alt text

eykanal
That totally works. Out of curiosity, what if I didn't have excel?
hookedonwinter
If you know (and own) matlab, you can import and transpose matrices easily using that, but that's a niche answer. You could try to write a simple shell script to do it, but it would probably be a PITA if you're not familiar with scripting.
eykanal