https://github.com/muhanedahmed/bashscript-database-project
A project on bash scripting course during the ITI simulating a database engine.
https://github.com/muhanedahmed/bashscript-database-project
bash-scripting dbms-mini-project linux-app
Last synced: 3 months ago
JSON representation
A project on bash scripting course during the ITI simulating a database engine.
- Host: GitHub
- URL: https://github.com/muhanedahmed/bashscript-database-project
- Owner: MuhanedAhmed
- Created: 2025-03-20T15:06:36.000Z (3 months ago)
- Default Branch: main
- Last Pushed: 2025-04-04T16:59:10.000Z (3 months ago)
- Last Synced: 2025-04-04T17:35:25.672Z (3 months ago)
- Topics: bash-scripting, dbms-mini-project, linux-app
- Language: Shell
- Homepage:
- Size: 109 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Bash Shell Script Database Management System (DBMS)
## Overview
This project is a simple Database Management System (DBMS) implemented using Bash shell scripting. It provides a Command Line Interface (CLI) and a Graphical User Interface (GUI) using `Zenity` for managing databases and tables.## Features
- Create, List, Drop Databases
- Create, List, Drop Tables
- Insert, Select, Update, Delete Records
- Data Validation (Strings, Numbers, Dates, Primary Keys, etc.)
- Error Handling and User-Friendly Messages
- CLI and GUI Support (via Zenity)## Project Structure
```
DBMS-Project/
├── CLI-Version/
│ ├── Main_Menu.sh # Main menu script for CLI version
│ ├── Table_Menu.sh # Table operations menu
│ ├── Utils.sh # Helper functions for validation and database handling
├── GUI-Version/
│ ├── Main_Menu.sh # Main menu script for GUI version (Zenity-based)
│ ├── Table_Menu.sh # Table operations menu for GUI
│ ├── Utils.sh # Shared helper functions
├── DBs/ # Directory storing databases and tables
│ ├── /
│ │ ├── .meta # Table schema definition
│ │ ├── .data # Table records storage
└── README.md # Project documentation
```## Requirements
- Linux/macOS
- Bash 4+
- `Zenity` (for GUI version)## Installation
1. Clone the repository:
```bash
git clone
cd DBMS-Project
```
2. Ensure execution permissions:
```bash
chmod +x CLI-Version/*.sh GUI-Version/*.sh
```## Usage
### CLI Version
Run the main menu:
```bash
./CLI-Version/Main_Menu.sh
```### GUI Version
Run the GUI version using `Zenity`:
```bash
./GUI-Version/Main_Menu.sh
```## Database Operations
### Creating a Database
- In CLI: Choose `Create Database` from the main menu and enter a name.
- In GUI: Enter the database name in the prompt.### Creating a Table
- Define table name, columns, and primary key.
- Supported data types: `num`, `str`, `date`.### Inserting Data
- Records must match the table schema.
- Primary keys must be unique.### Selecting Data
- Supports full table selection or filtering by column values.### Updating & Deleting Data
- Users can update or delete records based on column conditions.## Validation Rules
- Database/Table names must start with a letter and can contain `[a-zA-Z0-9_#@$]`.
- String inputs cannot be empty or contain `:`.
- Numbers must be integers or floats.
- Dates must follow the `DD-MM-YYYY` format.## Contribution
Feel free to contribute by submitting pull requests or reporting issues.## License
This project is licensed under the MIT License.## Contributors
This project was developed by:
- [Shahd Fayez](https://github.com/shahd77fayez)
- [Mohaned Ahmed](https://github.com/MuhanedAhmed)