Enter your email address:

Delivered by FeedBurner


Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
how to export a csv using INTO syntax of mysql
12-13-2011, 12:12 AM
Post: #1
Sad how to export a csv using INTO syntax of mysql
Guys if you want to study mysql from scratch click the above mysql tab.
Here we are going to learn how to export a database table as a csv file in mysql.
Assuming you have a table "login" or just create a table login or whatever name.
Create table login(name varchar(20),pass varchar(20));
then insert some values.

In mysql console type as shown below.

mysql> select * from login into outfile 'c:/login.csv' fields
terminated by ',
'enclosed by '"'lines terminated by "";


Now you will find csv file in c:/login.csv. Any doubts ask us.

Happy coding
Find all posts by this user
Add Thank You Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies Views: Last Post
Tongue Retrieve values between two numbers in mysql rajasri 0 1,133 12-13-2011 12:09 AM
Last Post: rajasri
Smile How to backup database of mysql using bat rajasri 0 844 12-12-2011 10:11 PM
Last Post: rajasri
Wink Exception:com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for colu rajasri 0 1,715 12-12-2011 09:39 PM
Last Post: rajasri

Forum Jump:


User(s) browsing this thread: 1 Guest(s)

Like Our Facebook Page