We are aiming to create an online library management database system that will allow for users to easily track books and the different services that the library offers for them. The system will simplify the process of how to browse a catalog of books, borrow/return books, and request books not currently in the library. This system will greatly improve the efficiency of library services.
Tables & Relationships: Books - book_id (PK), title, author_id (FK), genre, publish_year (int), is_available (boolean) Authors - author_id (PK), name, nationality Members - member_id (PK), name, email, membership_date (date) BorrowRecords - record_id (PK), book_id (FK), member_id (FK), borrow_date (date), return_date (date), status (borrowed/returned) OrderRequests - request_id (PK), member_id (FK), book_title, author_name, request_date (date), status (pending/fulfilled) Authors to Books: one to many relationship, Members to BorrowRecords: one to many relationship, Members to BorrowRecords: one to many relationship, Members to OrderRequests: one to many relationship.
User Roles: Librarian (Admin): Add/edit/delete books, Manage borrow/return records, View/process book requests, Add/edit/delete member Member (Regular User): Browse available books, Borrow and return books, Request new books
Setup Steps:
- Download MYSQL (using 9.3)
- Download IntelliJ IDEA and Tomcat
- Sync Maven dependencies using pom.xml
- Configure Tomcat with WAR created by project after building it (images below)
- Default url should be http://localhost:8080/library/
- Start MYSQL
- Change create_schema.sql to desired user and password
- Change db.properties.template to db.properties and change to desired user and password
- Run create_schema.sql once by using . (path to create_schema.sql) with the root user (or user with admin privileges) of your MySQL configuration
- Populate with sample data by running initialize_data.sql (if desired)
- Run Project with Tomcat (future runs skip all steps except 6 and 11)
Relevant images -
Syncing Maven dependencies:
Building WAR:
Configuring Tomcat:
- Find path to Tomcat
- Deployment settings (make sure to rename the application context to library)








