<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Tolu Adesina</title>
    <description>The latest articles on DEV Community by Tolu Adesina (@toluadesina).</description>
    <link>https://dev.to/toluadesina</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F239225%2Fe0494ccb-485d-499b-8e68-001c334a9e88.jpg</url>
      <title>DEV Community: Tolu Adesina</title>
      <link>https://dev.to/toluadesina</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/toluadesina"/>
    <language>en</language>
    <item>
      <title>How to Install MySQL on Mac</title>
      <dc:creator>Tolu Adesina</dc:creator>
      <pubDate>Mon, 30 Sep 2019 13:55:20 +0000</pubDate>
      <link>https://dev.to/toluadesina/how-to-install-mysql-on-mac-4iea</link>
      <guid>https://dev.to/toluadesina/how-to-install-mysql-on-mac-4iea</guid>
      <description>&lt;p&gt;First Check if you have MySQL installed on your Mac.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Type mysql in your terminal&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If you have mysql there, you can get different types of messages, one that you might get is this one&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;Error 1045 (28000): Access denied for user 'username'@'localhost' (using password: NO)&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;This way you will know you have mysql installed, but if you get an error saying something like;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;-bash: /usr/local/bin/mysql: No such file or directory&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;This way we know that &lt;code&gt;mysql&lt;/code&gt; is not installed, we then go ahead to &lt;a href="https://dev.mysql.com/downloads/file/?id=486026"&gt;mysql.com&lt;/a&gt; to download the mac version.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;click that link above — it already has mac version selected&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Double click on the downloaded file.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--kUza0s45--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/9k2ycv2ylq2iud8ibu86.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--kUza0s45--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/9k2ycv2ylq2iud8ibu86.png" alt="Installing Mysql"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Follow the installation process, and then when you get to the point where you are asked to create a password, make sure you do create a password you would remember.&lt;/p&gt;

&lt;p&gt;Boom! Finish the process and be Happy!&lt;/p&gt;

&lt;p&gt;...&lt;/p&gt;

&lt;p&gt;That’s not all. that’s the first part!&lt;/p&gt;

&lt;p&gt;...&lt;/p&gt;

&lt;p&gt;Now that we have MySQL installed, let’s make sure it is accessible anywhere on the computer.&lt;/p&gt;

&lt;p&gt;But before that, let’s just check to make sure it is working properly.&lt;/p&gt;

&lt;p&gt;Open System Preference and click on MySQL logo&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--MHBD8PGN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/1jmdvu932o06sg044sln.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--MHBD8PGN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/1jmdvu932o06sg044sln.png" alt="Start MySql"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;So now that we know it is working, let’s add the PATH, so we can use terminal to access MySQL from anywhere on our system.&lt;/p&gt;

&lt;blockquote&gt;
&lt;blockquote&gt;
&lt;p&gt;Open Terminal&lt;br&gt;
cd to root ~/&lt;/p&gt;
&lt;/blockquote&gt;


&lt;/blockquote&gt;

&lt;p&gt;then run this command to see all the files you have, just to be sure you have .bash_profile file on your system.&lt;/p&gt;

&lt;p&gt;so you run &lt;code&gt;ls -al&lt;/code&gt; and then scroll till you find &lt;code&gt;.bash_profile&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--IPl-p-2g--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/zjcancfv140iom34mqka.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--IPl-p-2g--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/zjcancfv140iom34mqka.png" alt="Edit Bash Profile"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you do not have &lt;code&gt;.bash_profile file&lt;/code&gt;, simply run &lt;code&gt;touch .bash_profile&lt;/code&gt; and you would have created a file called &lt;code&gt;.bash_profile&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Now that we have &lt;code&gt;.bash_profile&lt;/code&gt; we open it with the following command;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;open -t .bash_profile&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;This way you open up the &lt;code&gt;.bash_profile&lt;/code&gt; in the text editor and then you should add this line to the file;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;export PATH=${PATH}:/usr/local/mysql/bin/&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;Now you should save the text file and then close the terminal instance.&lt;/p&gt;

&lt;p&gt;Restart your terminal and then run &lt;code&gt;mysql -u root -p&lt;/code&gt; in your terminal.&lt;/p&gt;

&lt;p&gt;You should get something looking like this.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--l_pIVmD9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/vsmyd66jhb600b3gj6h1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--l_pIVmD9--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://thepracticaldev.s3.amazonaws.com/i/vsmyd66jhb600b3gj6h1.png" alt="Run MySql"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;...&lt;/p&gt;

&lt;p&gt;Now you can write your MySQL codes and be Happy! 😁&lt;/p&gt;

&lt;p&gt;...&lt;/p&gt;

&lt;p&gt;Thank you for your time. I hope you’ve enjoyed reading this article.&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>mysql</category>
      <category>tutorial</category>
      <category>sql</category>
    </item>
  </channel>
</rss>
