What Will I Learn?
<ul>
<li>How to create MySQL Database
<li>How to create MySQL Table
<h4>Requirements
<ul>
<li>Xampp
<li>PC (Windows )
<h4>Difficulty
<ul>
<li>Basic
<h4>Tutorial Contents
<h4>What is MySQL ?
<p dir="auto">MySQL is a database software relation (Relational Database Management System or RDBMS), as well as ORACLE, Postgresql, MS SQL, and so on. MySQL was developed around 1994 by a software development company and database consultant named MYSQL AB residing in Sweden.
<h4>Now just go to the tutorial, follow the steps below:
<ul>
<li>The first step should you do open the xampp mysql to enable application press start on mysql to activate it follow like below.
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517928908/vjdiuaflvgeu6ttub93t.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517928908/vjdiuaflvgeu6ttub93t.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517928908/vjdiuaflvgeu6ttub93t.png 2x" />
<ul>
<li>After that you guys open command prompt click start in windows after that you guys search for cmd
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931650/m7xrrz0o9i9orimzdqml.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931650/m7xrrz0o9i9orimzdqml.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931650/m7xrrz0o9i9orimzdqml.png 2x" />
<ul>
<li>After opening the cmd to get out like the picture below
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931590/od4yipascrcuw85d8uuz.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931590/od4yipascrcuw85d8uuz.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931590/od4yipascrcuw85d8uuz.png 2x" />
<ul>
<li><p dir="auto">Before we get to the tutorial how to create a database we go first to the mysql server please follow as below.
<li><p dir="auto">Type <code>cd \ this command is used to switch to directetori C
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931695/h3y6prgbzq68fmtlevjz.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931695/h3y6prgbzq68fmtlevjz.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931695/h3y6prgbzq68fmtlevjz.png 2x" />
<ul>
<li>Next you guys type command<code>cd xampp like below and press enter
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931738/jcgx9xzeql02ykj9cfjh.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931738/jcgx9xzeql02ykj9cfjh.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931738/jcgx9xzeql02ykj9cfjh.png 2x" />
<ul>
<li>Next type command <code>cd mysql and press enter
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931852/hwcew5vxmlgiydqs5jro.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931852/hwcew5vxmlgiydqs5jro.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931852/hwcew5vxmlgiydqs5jro.png 2x" />
<ul>
<li>After typing the command <code>cd mysqlnext you guys type <code>cd bin and press enter
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931892/g1k3tsuhr6feeovostpa.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931892/g1k3tsuhr6feeovostpa.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931892/g1k3tsuhr6feeovostpa.png 2x" />
<ul>
<li>Now you guys type the commands <code>mysql – u root to get into your mysql server and press enter to exit as below, once it comes out like the picture below means you guys managed to get the mysql server
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931961/apecfjlzvd0lejztyjtz.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931961/apecfjlzvd0lejztyjtz.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931961/apecfjlzvd0lejztyjtz.png 2x" />
<ul>
<li>Next you guys type the command <code>create database dbardifitra;then press enter, so it comes out like the picture below
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931981/rakcygyqhutuqpdhfj8b.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931981/rakcygyqhutuqpdhfj8b.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517931981/rakcygyqhutuqpdhfj8b.png 2x" />
<ul>
<li>After we make the data base we now see databases that we have created earlier with the way type the command <code>show databases;then press enter
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932293/aq9hzkw4vwz9e0n4vb3v.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932293/aq9hzkw4vwz9e0n4vb3v.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932293/aq9hzkw4vwz9e0n4vb3v.png 2x" />
<ul>
<li>After successfully creating a database we will now create a table, before we make our table select the first database that would like to use to create the chart, an example I will now select the database dbardifitra, how to select a command type <code>use dbardifitra; see the image as shown below
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932365/orx2vpt1ylvbjkqiet2n.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932365/orx2vpt1ylvbjkqiet2n.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932365/orx2vpt1ylvbjkqiet2n.png 2x" />
<ul>
<li>After the above command to select the database that you want to use it we will make the table, to make the chart type command<code>create table tbardifitra ( NIK int not null, Name char(20), Place char(50) ) like the image below and then press enter
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932248/r3obpd0euob01oodfsdh.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932248/r3obpd0euob01oodfsdh.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932248/r3obpd0euob01oodfsdh.png 2x" />
<ul>
<li>To see the structure of the table that we've created last type the command <code>desc tbardifitra; then press enter look like the image below
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932448/hau9hvvdlums0rvqnocm.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932448/hau9hvvdlums0rvqnocm.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932448/hau9hvvdlums0rvqnocm.png 2x" />
<ul>
<li>To see a table who've we created last type the command <code>show tables; then press enter look like the picture below
<p dir="auto"><img src="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932697/ecjl5v65emtaou2uon74.png" alt="image" srcset="https://images.hive.blog/768x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932697/ecjl5v65emtaou2uon74.png 1x, https://images.hive.blog/1536x0/https://res.cloudinary.com/hpiynhbhq/image/upload/v1517932697/ecjl5v65emtaou2uon74.png 2x" />
<p dir="auto">Here's my tutorial, hopefully useful
<p dir="auto"><br /><hr /><em>Posted on <a href="https://utopian.io/utopian-io/@ardifitra/tutorial-how-to-create-mysql-database-and-tables-in-command-prompt" target="_blank" rel="nofollow noreferrer noopener" title="This link will take you away from hive.blog" class="external_link">Utopian.io - Rewarding Open Source Contributors<hr /><p>
Your contribution cannot be approved because it is a duplicate. It is very similar to a contribution that was already accepted here & here.
You can contact us on Discord.
[utopian-moderator]