Re: load data into temporary table

2009-05-19 Thread Janek Bogucki
Hi, mysql create temporary table t(i int); mysql \! echo 1 /tmp/data.txt mysql load data infile '/tmp/data.txt' into table t; Query OK, 1 row affected (0.00 sec) Records: 1 Deleted: 0 Skipped: 0 Warnings: 0 mysql select * from t; +--+ | i| +--+ |1 | +--+ 1 row in set

Re: load data into temporary table

2009-05-19 Thread Alex K
Thank you but the real problem occurs when you don't know the schema of the table in advance. If data.txt has two columns columns how can I still load it in a temporary table? I'm asking this question because I'd like to add an import csv feature to a web application. I know that you can load data

RE: load data into temporary table

2009-05-19 Thread Gavin Towey
, does not mean you must use LOAD DATA INFILE to get the data into MySQL. Regards, Gavin Towey -Original Message- From: alex.ksi...@gmail.com [mailto:alex.ksi...@gmail.com] On Behalf Of Alex K Sent: Tuesday, May 19, 2009 5:43 AM To: MySQL General List Subject: Re: load data into temporary