PostgresDataExporterGUI is a Python application that allows you to export data from a PostgreSQL database to a CSV file with the option to include images. The application provides a graphical user interface (GUI) for ease of use.
- Ability to input PostgreSQL database connection details, including username, password, host, port, and database name.
- Error handling for database connection exceptions.
- Input area for entering SQL queries to fetch data from the database.
- Handling of database query exceptions.
- Export fetched data to a CSV file.
- Option to include images in the exported data.
- Ability to choose the export directory.
- CSV file includes a column for images with image files saved in a specified directory.
- Customized Tkinter-based GUI with various components, including input fields, checkboxes, buttons, progress bars, and text areas.
- Custom exceptions (
DBConnectionException
,DBQueryException
,ExportCSVException
,SaveImageException
) for handling specific error scenarios.
- Instructions for creating and activating a virtual environment.
- Installation of project dependencies from the
requirements.txt
file.
- Python 3.10 or later
- Dependencies listed in
requirements.txt
-
Clone the repository:
git clone https://github.com/Macktireh/PostgresDataExporterGUI.git
cd PostgresDataExporterGUI
-
Create a virtual environment and activate it:
python -m venv .venv
for MacOS or Linux
source .venv/bin/activate
for Windows
.\.venv\Scripts\activate
-
Install dependencies:
pip install -r requirements.txt
-
Run the application:
python app.py
-
The GUI will appear, allowing you to input database connection details, a SQL query, and specify options for data export.
-
Click on the "Choisir un dossier" button to choose the export directory.
-
Click on the "Exporter" button to execute the data export process.
This project is licensed under the MIT License.