 Hey everybody, this is Brian and welcome to the fifth LAMP tutorial. This tutorial, we're going to test MySQL. I wanted to break this off into its own little tutorial because it's going to be a little more involved. So we're going to press Ctrl T to bring up the terminal. And one thing we want to install is called PHP MyAdmin. It's a very, very popular web-based tool that you can use to administer, well, you guessed it, PHP and also MySQL. So we're going to go to sudo appget install PHP MyAdmin. Hmm, oops, how embarrassing. sudo, sorry. And this will take a little bit of time to pull down. So while this is turning away in the background, we're going to open our web browser here and we're going to actually look up PHP MyAdmin. Once again, this is a virtual machine, so it's going to take a little bit to snap open. Whoops, it wanted something. Alright, so when we're installing PHP MyAdmin, it's going to want to know some information. For example, it's going to want to know which web server. Press space to put an asterisk there, tab. And periodically it'll say hey, I need passwords, I need this, I need that. So if you go to PHPMyAdmin.net, that's where you can actually look at this product. It's free of charge, of course. Read the documentation, download it. Even use a demo server and see how it works. You can also go to sourceforge.net projects PHP MyAdmin. This is one of the more popular packages for administering PHP and MySQL. Another one is, well, let's look up MySQL. MySQL.com. See if this is asking for a password yet. And then click on downloads. Now you'll see this little thing called MySQL Workbench GUI, or GUI Graphical User Interface Tool. Click on that. And now we need to select our platform. I'm on Ubuntu Linux. And then of course it pops open and says okay, what type of Ubuntu Linux do you want to do? What type am I? That's a very good question here. I know I'm 32-bit. And if they ask you to register, just click no thank you to start my download. That's one thing that I do love about the open source community is they don't really force things down your throat. So we're just going to download this package. And while that's downloading, we'll check on this. Okay. PHP MyAdmin package must have the database installed and configured before it can be used. This can be optionally handled with DB Confed.com. Basically really all this is saying is if you're an advanced user click no, otherwise click yes and let it do what it needs to do. Not once to know the password for the databases administrator. Not once the MySQL application password for PHP MyAdmin. This is going to be the actual webpage. And if you read in the screen you can see it actually does restart the Apache 2 and brings it back online. Now once you get to this command prompt here you know that you are successfully installed it. So how do we use this thing? Let's go back to our web browser here. Now you know that if you go to 7.001 or your local loop back that is your test server. That's your actual web server right there. Now if you do slash or whack as they call it PHP MyAdmin you'll be greeted by this little page. And this is actually the PHP MyAdmin login page. So give it the username and the password that you entered and notice that cookies must be enabled past this point. Now this thing can get fairly involved fairly quickly. I'm not going to cover the SQL language. I'm simply showing you the tools and verifying that MySQL is actually working in this tutorial. We'll cover all that later in other tutorials. But because this is this whole series is designed for somebody who has no knowledge of any of this whatsoever. I'm going to keep it very simple, very straightforward, very linear in approach. So this tutorial like I said is just simply we're verifying that MySQL is working. And as you can see there's MySQL's database and here's some of the other databases. PHP MyAdmin has its own database and there's a test database. Click on MySQL and you can see wow yeah there's a lot of stuff in there. Well if you see this stuff we've just proven that MySQL is actually running because we were loading information from the MySQL database. And you can go into the test database and just kind of poke around and see what's in there. Notice there's nothing in the test database and create tables which if you don't know anything about databases you have no idea what a table is. Like I said we're going to cover all of that later. We're just testing to make sure all this stuff works. We want a solid platform to move ahead on. PHP MyAdmin is very powerful because it's web based you can use it on any platform with a very little headache. And it has a lot to it. I mean there's a lot of stuff you can do here. So just kind of poke around, look at it, make sure it reads the documentation. It's a little bit more for advanced users. For new users we're going to actually check out the MySQL workbench, the GUI tool. I wonder if that's done downloading yet. Yep it's done downloading good. So we'll simply go to downloads and right click and open up Ubuntu Software Center or you could have just double clicked it. There we go. So now we've got the MySQL workbench. As you can see it's like any other software you've installed. So just click install. Let it do it's thing. And you need your administrative password. Some people love the MySQL workbench. Some people hate it. Some people swear by it. I personally have never really used it very much. I'm still relatively new to SQL, sorry SQL, PHP and MySQL. I've always been more of a ASP.net C-Sharp, PB with Microsoft SQL. So a lot of this I've actually learned fairly recently. That being said, if you know better tools feel free to contact me I made or may not throw out a tutorial on them. And you can see the little windows popping open. That's the MySQL workbench reading the configs and the databases and populating all the information that it needs. Now when I was testing it out earlier on a different virtual machine I had to actually hide the launcher over here. I just don't have enough screen real estate on this virtual machine. I can make the resolution bigger but it would also make the size of the video bigger, which I'm not too fond of. Let's close this. Let's give it some clutter here real quick. Alright, let's see. MySQL workbench. Let's look at this thing. Well that's loading. I should probably prepare my settings real quick here. Hello MySQL workbench. You're going to start. There we go. Now this is what I meant by on my resolution it's a little quirky. You notice how it cuts it off. So I'm going to go to appearance and I'm going to auto hide the launcher. Now suddenly you can see the entire screen. Now a lot of this may be foreign to you if you know nothing about databases. Just looking at this I mean you can see it's fairly involved. Fairly complex little workbench here. The first thing we need to do is make a connection. See, manage connections. We're going to make a new connection. I'll just call it new connection one. And if you don't know what any of this stuff is just leave it be. You want to click store and keychain and type in the password that you entered when you installed MySQL. And it'll say are you sure. It gives you a little password strength meter down here too. Now test the connection to make sure you can actually do it. And ta-da! If you've gotten this far you know that MySQL is actually running. But we're going to keep going. We're going to close this. And you see our new connection is right here. Simply double click that. You'll see it says connecting down here. And Shazam! There we go. There is in all its glory our current databases. So let's just kind of browse around here. We can do different tabs create schema, create tables, etc. There's a lot of options in here and I would really implore you to look around. Once again read the documentation, get used to everything. Both of the tools that I've just shown you have a wealth of information out there. Like I said we're not really going to cover a whole lot of you know how to actually do things. We're just making sure that it's working at this point. But you can see how you have these different databases and you can go in and do different things. You can create multiple tabs. This is one thing I like about MySQL workbench is it's really designed for someone who's multi-tasking and has a lot going on at once. So anyways that's it for this tutorial. I just wanted to keep it short and simple. If you've been following this series so far we have installed frog in my throat. So far we have installed Ubuntu Linux on a virtual machine. We've installed Lambs Linux, Apache, MySQL and PHP and we have verified that all of that is working. So we are now ready to go. Everything's up and running. The only thing we have to do next is start, well you guessed it, start writing code and learning how to do PHP. So this is Brian. Thank you for watching. It's 9 o'clock at night. Time for me to play World of Tanks, my newest addiction.