Handle .sql file

-1

I have a * .sql file. How do I transfer / use a database?

Have the records in the database. (it was sent to me and I do not know how to have the data inside my database, and then use it with php)

    
asked by anonymous 27.08.2017 / 17:36

2 answers

0

The * .sql file does not represent the database, it does not contain the records, nor is it a copy of it.

This is a script file, it can contain database creation, queries, table creation, inserts, and other SQL operations.

You can open it using a text editor, but most of them (at least natively) will not be able to run this script.

As you have put the tag in the question, you can open MySQL Workbench, connect to a MySQL instance, and open the file using CTRL + O in Windows or ⌘O in macOS. p>

If you have no instance of MySQL installed, follow link .

    
27.08.2017 / 17:45
0

Hello, if it's in phpmyadmin, you should click import

And then you click on browse and choose the sql file and just below you click execute. If it does not work you can create a database and then import the data ... I hope I helped you

    
27.08.2017 / 17:51