importing sql file into a database using wamp

 ̄綄美尐妖づ 提交于 2019-11-30 18:50:45
Meer

Option 1; PHPMyAdmin

1. left click wamp -> phpmyadmin
2. select database then click import (top right)
3. locate the database and click go.

Option 2; Using the command line.

The easiest way to import a sql file into a database in WAMP, using command line is as follows:

1. Open Command Prompt (CMD - DOS) get into the mysql folder, which in my case works like this
C:\> cd C:\wamp\bin\mysql\mysql5.0.51b\bin

2. Then use this command to fire up MySQL
   This line basically connects you to the mysql database of your choice.
   (-p for password if you have one)
C:\wamp\bin\mysql\mysql5.0.51b\bin> mysql.exe -use databasename -u username -p

3. To make things easier, copy the SQL file into the same folder as mysql.exe, and then run this
mysql> source myfilename.sql;
Subodh Kumar
  1. OPEN your filename.sql in NOTEPAD.....

  2. COPY all content..... left

  3. Click wamp>phpmyadmin.....

  4. CREATE new Database.....
  5. and Click on SQL tab and PASTE the content.....
  6. then Click on GO..... Hurray!

    you have done

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!