This project involves managing a PostgreSQL database using Python and the Psycopg2 library. The project includes functionalities such as creating tables, inserting data, querying the database, executing stored procedures, and more.
- Database Connection: Establish a connection to a PostgreSQL database using Psycopg2.
- Table Management: Create, delete, and manage database tables.
- Data Operations: Insert, update, delete, and query data in the database.
- Stored Procedures: Execute PostgreSQL stored procedures and functions from Python.
- Error Handling: Robust error handling and logging mechanisms.
- Python (version = 3.11)
- PostgreSQL Database
- Psycopg2 Library
-
Clone the Repository:
git clone https://github.com/wonderakwei/PostgreSQL-Database-Management-with-Python-and-Psycopg2.git
-
Navigate to the Project Directory:
cd PostgreSQL-Database-Management-with-Python-and-Psycopg2
-
List All Databases:
\list
-
Change Directory / Database:
\c schdbm
-
Display Tables in the Database:
\dt
-
Display Table Content:
SELECT * FROM students;
- Python
- PostgreSQL
- SQLShell
- Git
- PowerShell