import data mysql to excel & excel to mysql

18
Import data from Mysql to Excel Presented by, Thooyavan V

Upload: thooyavan-venkatachalam

Post on 16-Apr-2017

78 views

Category:

Education


16 download

TRANSCRIPT

Page 1: Import data MySQL to Excel & Excel to MySQL

 Import data from Mysql to Excel

Presented by,Thooyavan V

Page 2: Import data MySQL to Excel & Excel to MySQL

Step  1:  Download  the  driver  from  the  website  which  is  given below.  First  drive(8.0  M).  After  downloading,  install  it  in  your system

Page 3: Import data MySQL to Excel & Excel to MySQL

Step  2:    Go  to  Control  panel->  Administrative  Tools-> Select  Data  source(ODBC).  Below  dialog  box  will  open.

Page 4: Import data MySQL to Excel & Excel to MySQL

Step 3: Click Add. Then select below image

Page 5: Import data MySQL to Excel & Excel to MySQL

 • Step 4: Click Finish. Then give  the necessary 

details which is shown below. 

• In the name, description field give any name. 

• In  Database  field,  select  the  database  from 

the  drop  down  menu.

Page 6: Import data MySQL to Excel & Excel to MySQL

Step 5: Click ok

Page 7: Import data MySQL to Excel & Excel to MySQL

Step  6:  Now  Open  Excel,  In  Data  field->  select Connection->Select Add->Select Browse for more->select +Connect to New data Source-> Click Open

Page 8: Import data MySQL to Excel & Excel to MySQL

Step 7: 

Page 9: Import data MySQL to Excel & Excel to MySQL

Step 8: Select the data source as the name which is given earlier(i.e.,excelmysql1)

Page 10: Import data MySQL to Excel & Excel to MySQL

Step 9: Select any Database name. Here I gave mark database for Example.

Page 11: Import data MySQL to Excel & Excel to MySQL

Step 10: Click finish

Page 12: Import data MySQL to Excel & Excel to MySQL

• Step  11:  Now  In  same  Excel->Data  Tab-> 

select  Connection->Select  Existing 

Connection

• Step 12: Here select database table name.

Page 13: Import data MySQL to Excel & Excel to MySQL

For Example,

Page 14: Import data MySQL to Excel & Excel to MySQL

Step:13:

Click OK.

Page 15: Import data MySQL to Excel & Excel to MySQL

Step 14:Now the data from the database will get displayed in Access like this

Page 16: Import data MySQL to Excel & Excel to MySQL

Import data from Excel to Mysql

Page 17: Import data MySQL to Excel & Excel to MySQL

• In mysql create a database and table with particular fields.

• In Excel, give the data alone(Without field name).

• Save the excel in .csv (Comma separated) format.

• Open Mysql• Use database name;

Page 18: Import data MySQL to Excel & Excel to MySQL

• Give the Query to import from excel to mysql:  

• load data infile ‘Give the path of ur .csv file’ into table table_name fields  terminated by ‘,’ lines terminated by ‘\n’;

• Then see the data by the query: select * from table name;