Welcome to PostgreSQL Starter Package!
Hey this is Avishek Das and welcome to my PostgreSQL starter Pack. Here I will show a you step by step guide from the beginning to advance roadmap of PostgreSQL. Stay tuned.
1. Installation
Being a Windows user I will show the steps & all the hassles for Windows only. For MAC and Linux Installation I will refer to these sites -> Mac , Linux . Actually they are very straighforward so don't worry.
Step1: Download the appropriate version from here.
Step2: Install normally , give a password when prompted & let the installation finish.
Notice that postgres is the default superuser here.
Step3: From you Application menu pick the PgAdmin4 and SQL Shell and drag them to your Desktop.
- PgAdmin4 is the GUI version where you can manage all the works of Postgres
- and SQL Shell is the CLI version(which we shall often use)
Step4: Now just open you CMD or Any other windows CLI and type psql
Command is not recognized!!! ๐ฑ COOL DOWN i got you ๐คEnvironment variable setup
Goto installation directory and copy the bin location
C:\Program Files\PostgreSQL\12\bin
Now simply add this to your system/user environment. (You may go through this guide if you are new to environment variable setup)
OK, NOW AGAIN, open you CMD or Any other windows CLI and type psql
Hola!!! Now the command is recognized. Enter the password. GOT another one!! ๐ ... Again Got YOU.Set the Default username
Open you CLI and just type
set PGUSER=postgres
Finally type psql and enter the pass.
Congratulations!!! You have overcome all the hassles ๐