Introduction to PostgreSQL: up and running

What is PostgreSQL?

Naming conventions in PostgreSQL

  • Tables || Indexes == Relations
  • Row == Tuple
  • Column == Attribute
  • Data Block ||Data cell == Page (on the disk) && Buffer (on memory)

Installing and setting up PostgreSQL on windows

Verifying the installation

  1. Checking windows services
    Go to search>services: and look for postgreSQL running as a service. If you see a running instance of postgreSQL in the list, you have successfully installed the ORDBMS.
  2. PSQL (SQL shell)
    Go to search>psql: open the sql shell. On opening the shell, it will ask a couple of questions.
    Server[localhost]: (since the server is installed in the local host, nothing as to be done here, you can simply press enter)
    Database[postgres]: (By default, postgreSQL creates a database called postgre when we haven’t created any database. nothing has to be done at the moment, you can simply press enter)
    Port[5432]: (press enter)
    Username[postgres]: (press enter)
    Password for user postgres: type your super user password here (press enter)
    you can view databases by hitting \l in the shell. You can see a couple of default database created by postgreSQL even before you create any database. \q is used for quitting the shell.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store