How To Install Postgresql

How To

How To Install Postgresql Video

postgresql tutorial

How To Install Postgresql Video Transcript

postgres 10 install

welcome back we’re going to start setting up Postgres on our computer so that just like we did with servers and front end we’re gonna have a terminal that’s running our front end and a back end that is running our server but also another terminal that is running a database because as you remember these are just computers running somewhere in the same way that we ran our server on our computer we can also run our database on our computer and in this video we’re gonna get us set up with Postgres now MongoDB has gotten popular however nothing beats a relational database for really developing your knowledge of databases once you understand relational databases it gives you really really good tools and mental models to work with MongoDB MongoDB is very very simple you can think of it as a JSON data structure where we just have JSON that looks like an object and we store that information there with SQL and relational databases it’s more complex than that so if you understand this you are miles ahead when it comes to understanding databases so we’re gonna be focusing on that because the principles are still the same for MongoDB all right so let’s get Postgres set up on our computer the first thing we want to do is download something called a GUI so a graphical user interface for Postgres and this exists for pretty much any database out there I like P sequel because it’s free it’s really really good for Mac and it’s very light and simple I’ll also make sure to add notes on how to download something like this and Postgres in general if you’re using a Windows machine but otherwise just click on the download link it’ll be completely fast just open it up and you’ll have something like this that I’m gonna be using throughout the course but there’s many many options you can take a look for it you just search for Postgres SQL GUI and once you have P sequel installed you’ll have it in your application folder and you can follow along now let’s go back to the terminal in order to have post Kristen’s told there’s many many ways and again I’ll provide some notes on how you can do it but the best way especially on Mac is to use brew which we’ve already talked about every time you do something with homebrew again it’s a way to download packages from the internet on your terminal you always want to make sure that you do a brew update to make sure that everything is updated and also a brew doctor which just make sure everything is working on your system let’s clear that perfect once you have that set up we’re going to just say brew install Postgres SQL and this will install for us Postgres and you see over here that I already have postcards installed but if it’s your first time it’ll run through the commands and then actually at the end tell you exactly how to start using it but in our case I’ll just Ellie it’ll be much easier to start Postgres you need to do brew services start Postgres and don’t worry this isn’t Postgres specific any database that you are downloading you’re essentially downloading the software and then you want to start the service each one has its own commands but it’s as simple as going in figuring out how to run the database so we’ve started Postgres SQL it looks like I’ve already started the service and just to show you if I actually do stop here it will stop the Postgres service and let’s do start again and you can see that it’s starting now in order for us to use Postgres we need to create a database and the way we do that is to use the create DB command that has come once we’ve installed Postgres and here we can call it whatever we want so let’s call it test it’s gonna create the DB and there you go here’s the cool part if I go back to my P sequel open this up let me close this I have over here P sequel and it asks for the host which is the link to where the database is located in my case it’s located at my local host right it’s running on my computer so you want it to be localhost and the port number this is the default port number of five four three two remember how we had port three thousand and three thousand and one for the front end and back end it’s similar to that it’s opening up a port for it to listen to the database and this is the standard port for Postgres that you’ll see so when I did the started Postgres and create DB the default of five four three two was already set I can actually set what port and change it up but we want to keep everything standard so we’ll keep it the way it is if I now go to the database and we call the tests so again we’ll do test database hit connect all right we’re connected to the database but there’s no much in here is there but at least we know that we’re connected to localhost test and another way to connect to this remember this is a GUI a graphical user interface and I’m showing you this because it’s really good for demo purposes but I want you to get comfortable working with the terminal as well in order to do the same thing we just did with the GUI we can type in psql again which is a command that we’ll get when we install Postgres and we’ll say which database we want to connect you in our case will be the test and there you go just like when we run node and it changes terminals now we’re inside of Postgres that’s running on our computer but we don’t know any commands yet Dewey so in the next video we’re gonna learn some SQL commands and finally create some tables in our Postgres database I’ll see in that one bye bye

install postgresql linux

How To Install Postgresql Related Keywords

how to install postgresql on windows step by step

how to install postgresql on windows step by step, install postgresql linux, how to install postgresql in ubuntu, install postgresql mac, install postgresql enterprisedb, postgres 10 install, postgresql tutorial, install postgresql centos 7, install postgresql mac, install postgresql linux, install postgresql ubuntu, install postgresql enterprisedb, install postgresql centos 7, install postgresql windows server 2012 r2, download postgresql for windows enterprisedb, postgresql tutorial, how do i install pgadmin3, what is postgresql database server, how do i connect to a postgresql database, what is stack builder in postgresql