How to Install MySQL and Import a Sample Database

By | December 10, 2019


For the subsequent SQL lesson
series that we are going to cover, you may want to install MySQL to
follow along with the instructor. MySQL is an open-source software; this means the software
is free to most end-users. MySQL does offer a commercial license
for more advanced database requirements. First, check to see if your
computer is compatible to run MySQL. To do this, review this web page that will direct you to the MySQL forum
with information about compatibility. At RealPars, we love helping you learn so if you enjoy this video as
much as we enjoyed making it, Click the like button. subscribe and click the bell and you’ll receive notifications
of new RealPars videos. so you’ll never miss another one! The MySQL has a very easy to use installer to help the user download and
install all the MySQL options. So by using this URL, go to this web page. There are two options,
choosing the right file. If you have an online connection
while running the MySQL Installer, choose the
“mysql-installer-web-community” file. If you do NOT have an online connection
while running the MySQL Installer, choose the
“mysql-installer-community” file. This is a larger file and contains
most of the options required. When the file downloads, it will be
named: “mysql-installer-community”. After the download, double click on the “MySQL installer
community” file to begin the process. When the “msi” file has completed
installing the MySQL installer program, the following window will appear. As you can see, I have already installed
the options, listed in this window. By installing one product, I will show you how to install the required
options you may need for your project. A new user will left mouse click
and select the “Add” button to install the same options. This window will display all
of the uninstalled products. I am going to select the
product which I want to install, in the “Available Products” pane. I use the arrow button to move the product to the
“Products and Features to be installed” pane. I left mouse click and select “Next”
button to start the install process. After selecting the required product and left mouse clicking the “Next” button, the following window will appear, displaying
the option which is ready to install. I left mouse click and
select the “Execute” button. This will begin the install process. If you have any questions, this MySQL URL for installation
documentation will help. You can find this link in
the description as well. After a successful install,
left-click the “Windows” button. I then explore through the programs
to find the “MY SQL” folder. Now let’s startup,
“MySQL Workbench 8.0 CE”. MySQL Workbench is a graphical tool for
working with MySQL servers and databases. When the “Workbench” opens,
the following user interface will display. I Left-click and select the “MySQL
Connections, Local instance MySQL80” button. You may need to log in using the password
created during the install process. MySQL will now display the
user interface environment. We are now going to open and run a
script that has predefined our database. This is advanced
scripting, but don’t worry, the next few steps are easy to follow. Much of the scripting in this schema
will be explained in additional lessons. Start by selecting the “File” menu button and scroll down to “Open SQL Script”. In my system,
this folder is containing the script. I will open the script called
“realparssampledatabasev2.sql”. You can find the download link
for this file in the description. The script is loaded into
the new schemas window. Now let’s run the script to
create the RealPars database. Select and left mouse
click the lightning button. After selecting and running the script, the tables and relationships are created. Then data records will
be added for us to sample using a few queries and available to
follow along with the lessons available. The following window is located
at the bottom of the screen and informs us of success and
failures while running the script. Green checks are good,
Red X’s are not good. I refresh the “Navigator” pane by
clicking on the “Swirling Arrows” button to display the newly created
“realpars model” database. After the refresh,
the database will appear. Let’s run a quick query.
Left-click the “Tables” triangle. This will expand the “Tables” folder. Now Right-click over the “students” table. Left-click the “Select Rows, Limit 100”. Doing this will create a new query to
select the top 100 rows in the database. The new query is created
and runs automatically. The query lists all of the top 100 records. This data can now be exported to
Microsoft Excel by left-clicking and selecting the “Export recordset
to an external file” button. Select the file format you prefer. For Microsoft Excel,
choose “Excel Spreadsheet” file type. I name this file “Students_top100”. Then I press the “Save button”. I browse to the folder where
I exported the data record. I then open the “Excel Spreadsheet”
file by double-clicking on it. This concludes the video, “How to install
MySQL and import a sample database”. Please stay tuned for future SQL
lessons, soon to be released. These lessons will provide basic and
in-depth use of the SQL commands using MySQL and additional lessons on how to
use this language in automation for analytical reporting,
troubleshooting, and process development. If you would like to get additional
training on a similar subject please let us know in the comment section. If you enjoyed this video,
please press the like button. Check back with us soon for
more automation control topics. Want to learn PLC programming
in an easy to understand format and take your career to the next level? Head on over to realpars.com

15 thoughts on “How to Install MySQL and Import a Sample Database

  1. MD Shadman Shakib Post author

    Love you brother 💙💙❣️💙💙❤️…….. this YouTube channel is manY helpfull……… I see your all videos and share my friends….

    Reply
  2. Stone Evans Post author

    Very happy with this topic i hope to see more in relation to automation.Keep up the good work

    Reply
  3. Rubén Arce Post author

    I think that learning about the interaction between tia portal and MySql would be a nice topic.
    Thank you for the video 🙂

    Reply
  4. Jai krisz Kristen Post author

    Thanks sir for starting such a topics ,i would like to learn ,ccna networking routing and switching sir ,if u r plan next video series ,this course will help lot of students

    Reply
  5. Soualmi Aymen Post author

    nice explaining ,im master on sql scripting but what is the role of databases on automation

    Reply
  6. Morné Moolman Post author

    This is awesome! This will help me with a current project at work. Please post as much as possible. Thank you very much!

    Reply
  7. quoit99 training Post author

    Can you connect mysql to PLC and make live database? That will be handy and worth watching. Thanks!

    Reply

Leave a Reply

Your email address will not be published. Required fields are marked *