This project is a database system designed for managing military base information, including soldiers, missions, equipment, and tasks. The project includes a structured database schema and optimized SQL queries to retrieve relevant information.
- Stores military base data including locations, commanders, and equipment.
- Tracks soldier details such as rank, age, and mission participation.
- Logs permissions and leaves taken by soldiers.
- Records mission details, including start and end dates, targets, and casualties.
- Provides optimized SQL queries for retrieving essential military data.
military database.sql
: SQL script for creating the database schema.Queries.txt
: A collection of SQL queries for retrieving specific information from the database.military project.pdf
: Project documentation detailing the schema and required queries.
The project includes several queries that extract valuable insights from the database, such as:
- Listing bases in Virginia with air defense systems.
- Calculating the total age of soldiers with the rank of Major.
- Finding soldiers stationed at bases with commanders holding the rank of Colonel.
- Identifying soldiers on annual leave in California.
- Extracting details of bases using tank equipment.
- Identifying pending tasks assigned to soldiers operating helicopters.
- Listing soldiers and their commanders who were on leave in April 2024.
- Retrieving reports on missions targeting terrorists.
- Identifying missions using tanks and soldiers older than 25 years.
- Finding soldiers absent on mission days with high casualties.
- Listing missions with high unit losses using helicopters.
- Analyzing casualty percentages in Texas bases.
- Identifying missions involving soldiers under 28 years old.
- Finding soldiers with the highest number of annual leaves.
- Counting soldiers in bases with ongoing missions.
- Calculating the average age of soldiers participating in supply missions.
- Analyzing the percentage of soldiers taking sick leave in air-defense bases.
- Extracting details of tasks assigned to older soldiers with specific equipment constraints.
- Identifying bases with Captains participating in high-casualty missions.
- Listing equipment used in enemy-targeted missions from non-air-defense bases.
- Import the
military database.sql
file into a MySQL or PostgreSQL database. - Use the queries from
Queries.txt
to retrieve necessary data. - Modify or extend the queries based on specific requirements.
- MySQL or PostgreSQL database
- SQL knowledge to modify or extend queries
This project is licensed under the MIT License.
- Sayyed Hossein Hosseini DolatAbadi
- Amir Feiz