What is PostGresSQL ?
Installing PostgreSQL on Windows :
Basic Operations in PostGresSQL :
- PostgreSQL is a powerful, open source, object-relational database management system (ORDBMS).
- It is used to store data securely supporting best practices and allow retrieving them when request is processed.
- PostgreSQL is developed by the PostgreSQL Global Development Group.
- It is cross platform and runs on many operating systems such as Linux, OS X, Solaris, and Microsoft Windows etc.
PostgreSQL Features :
- PostgreSQL runs on all major operating systems i.e. Linux, UNIX, and Windows etc.
- PostgreSQL supports text, images, sounds, and video, and includes programming interfaces for C / C++, Java, Perl, Python, Ruby, and Open Database Connectivity (ODBC).
- PostgreSQL supports a lot of features of SQL like Complex SQL queries, SQL Sub-selects, Foreign keys, Trigger, Views, Transactions, Multiversion concurrency control (MVCC).
- In PostgreSQL, table can be set to inherit their characteristics from a "parent" table.
- We can install several extensions to add additional functionality to PostgreSQL.
Installing PostgreSQL on Windows :
- Search for postgress in google and go to official website.
- Click on the download link.
- Select the tool version and click on download now.
- Click on next.
- Choose the installation directory.
- Select the components want to install.
- Select the data directory.
- Create the password.
- Select the port number.
- Click on next.
- Click on finish.
- Open the pgAdmin to write the queries.
Basic Operations in PostGresSQL :
- To connect to server enter password that we created.
- To create database we can create in gui or query methods here i created in gui. We can also create a database by using CREATE DATABASE command.
- CREATE TABLE statement is used to create a new table in the database.
- The INSERT query is used to insert new rows into a table. We can insert a single row or multiple rows at a time into the table.
- The SELECT statement is used to retrieve data from a database table.
- UPDATE statement is used to modify the existing records in a table. To update selected rows, we have to use WHERE clause otherwise all rows would be updated.
- DETETE statement is used to delete the existing records from a table. The "WHERE" clause is used to delete the selected records, otherwise all the records would be deleted.