Generating MySQL Tables
| From: | Pete | Date: | Mon, 04 Oct 2004 20:32:40 +0000 |
| Subject: | Generating MySQL Tables | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-198613@lists.php.net to get a copy of this message | ||
Is MySQL off topic for this list? If so, I apologise.
I am supplied with various text (CSV, etc) data files, which I need to
manually massage before I import into the main database. I feel that I
can deal with them better by turning them into SQL tables first. I know
about LOAD DATA INFILE, but this requires a table to exist, and I don't
know the format of the table until I receive the text file.
Is there any simple way of automatically creating a table and then
importing the data?
If not, I think that I will have to create a dummy table, with, say, 50
blob fields (some text fields are 'a paragraph full'), and work from
there.
Of course, it doesn't need to be fast to run.
--
Pete Clark