Share
, , , ,

How to Turn PC into a Server

If you are looking for a way to practice MySql query creating a database for free then this post hopefully be helpful for you. You can create database in your own PC by creating server. It is very simple to turn a computer into a server. There are several way to do it but I will show you the most simple one. I will show you how to create a portable server by the help of XAMPP software. This software is totally free. By the help of this software you can create MySql server and you can practice MySql in your own PC. Here I have shown a few steps of the overall process and for your simplicity I have attached a sample SQL table which you can collect for your database.

Steps:


1. At first you have to download and install the suitable version of XAMPP for your PC from here.
2. After completing the installation run the programme. The UI should look like this-
XAMPP UI

3. Now, click on start button of Apache and MySql. Result-
Start Apache and MySql

4. Minimize the XAMPP window and open your browser and type- http://localhost and hit enter.
localhost

5. To create a MySql database click on phpMyAdmin tab. From the left panel click on new to create a new database.
phpMyAdmin

6. Now from the right panel give a name to your database and select the Collation as- utf8mb4_unicode_ci then press Create. Example-
Name DB

7. Your new database is created and ready to create a table. To create a table click on new under the name of your database.
Create Table


8. In the new window create number of columns as required, name them, select their type, set length and set a primary key for your table. An example is shown below-
Make column
9. Now, click on Save button at the below right corner. Then a new will appear where you will find your newly created table structure. Now, if you have any sql file import that or insert your table data clicking on Insert tab.
Insert Data

10. From the new window insert as many data as you want and press go. Example-
Insert Data

11. Every time you want to add data go to insert tab. You are done creating a database. Now you can practice MySql query going to the SQL tab.
Sql Query Window

Notice:

Some of you might face a problem after installing XAMPP. You might see an error notification like this-
XAMPP Error
In this case, press on Windows+R button and write- services.msc, run that. From the new window look for World Wide Web Publishing Service. Stop that service from running and close your XAMPP.
World Wide Web Publishing Service
Now, re-open the XAMPP.  I hope there won't be any problem now.



0 comments:

Post a Comment