you have to use 2 select for do this.
The first select generates the headerline and the second the data.
( SELECT 'FieldA','FieldB','FieldC', ... ) UNION ( SELECT `FieldA`,
`FieldB`, `FieldC`, ... INTO OUTFILE 'D:/data.csv'
FIELDS TERMINATED BY ',' LINES TERMINATED BY '\r\n' FROM ... ...
GROUP BY
I want to use
select * into outfile "myfile.txt" from table1;
and have it export the data as tab delimited but with the column names. I
need the column names because the import utility will use that to create
the table in another (non-MySQL) database.
As it stands, I can't get the column nam
At 05:39 PM 2/13/2011, Andre Polykanine wrote:
Hi all,
Hope this question is appropriate here :-).
I've got 4 queries:
$q1=mysql_query("SELECT *FROM`CandidateQuestions`WHERE
`Category`='1' ORDER BY RAND() LIMIT 1");
$q2=mysql_query("SELECT *FROM`CandidateQuestions`
Hi all,
Hope this question is appropriate here :-).
I've got 4 queries:
$q1=mysql_query("SELECT *FROM`CandidateQuestions`WHERE
`Category`='1' ORDER BY RAND() LIMIT 1");
$q2=mysql_query("SELECT *FROM`CandidateQuestions`WHERE
`Category`='2' ORDER BY RAND() LIMIT 1");
didn't u forgot to run mysql_intsall_db?
On Fri, Feb 11, 2011 at 6:53 AM, Adam smalin wrote:
> I accidentally drop the database mysql. I now cannot restore tables to the
> database or do much of anything some details can be found here
>
> http://serverfault.com/questions/234321/i-accidently-dr
That has got to be one of the most surreal conversations I've seen on a mailing
list!
Reminds me of the time I got tired of some boring lout on a Usenet group, and
so I wrote up a markov-3 "bot" that would automatically respond to his
postings, and then he got into a heated debate with himself.
I want to use
select * into outfile "myfile.txt" from table1;
and have it export the data as tab delimited but with the column names. I
need the column names because the import utility will use that to create
the table in another (non-MySQL) database.
As it stands, I can't get the column nam
I have a test process, which runs in the "old server" in 35 seconds, the new
server runs the same process in 110.
There is a change of version from mysql 4.1.22 to 5.1.22.
We were stuck at 5.1.22 because higher version give us another issules like
encoding, case sensitivity...
I really belive th