0% found this document useful (0 votes)
4 views15 pages

Project .Dbms

The Library Management System (LMS) project aims to automate and streamline library processes such as managing books, members, and staff, while ensuring accurate tracking of issued and returned books. It includes a user-friendly interface, a three-tier architecture, and various modules for book management, member management, and report generation. The project emphasizes database design, SQL optimization, and system testing, providing valuable insights into software development and management.

Uploaded by

ritikpatial946
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views15 pages

Project .Dbms

The Library Management System (LMS) project aims to automate and streamline library processes such as managing books, members, and staff, while ensuring accurate tracking of issued and returned books. It includes a user-friendly interface, a three-tier architecture, and various modules for book management, member management, and report generation. The project emphasizes database design, SQL optimization, and system testing, providing valuable insights into software development and management.

Uploaded by

ritikpatial946
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

PROJECT: LIBRARY MANAGEMENT SYSTEM

SUBMITTED BY: SUBMITTED TO:


Student Name: Ritik Name: Suman Acharya
UID: 23BCA10810 Designation: Assistant Professor
Branch: BCA
Section/Group: 5A
Subject: DBMS
Subject code: 23CAP-252
Introduction
Library Management System (LMS) is a software solution designed to streamline the processes
involved in managing a library. It offers functionalities like managing books, members, staff, and the
issuing and returning of books. This system ensures easy tracking of books, minimizes human error,
and allows for better management of resources.

Objective
The primary objectives of this project are:
• To design a database system that manages a library's books, members, and staff efficiently.
• To implement a user-friendly interface for easy interaction with the system.
• To automate the process of tracking books, managing inventory, and keeping a record of issued and
returned books.
• To ensure accurate and real-time updates for books available, books on loan, and overdue books.
• To provide an easy way to manage member accounts and staff responsibilities.

System Requirements
Hardware Requirements:
• Processor: Intel Core i3 or higher
• RAM: 4GB or more
• Hard Disk: 100GB or more
• Display: Minimum 1024x768 resolution
• Internet: Required for deployment and accessing online
documentation.

Software Requirements:
• Operating System: Windows 7/8/10 or Linux
• Database Management System: MySQL 5.x or higher
• Web Server: Apache (for deployment, if needed)
• Programming Language: SQL
• IDE: Any text editor (e.g., Visual Studio Code or MySQL Workbench)
System Architecture
Library Management System follows a three-tier structure:
1. Presentation Layer (UI): This layer interacts with the users and
provides an interface for viewing books, issuing/returning books,
managing members, etc. It is designed with HTML/CSS and can use
PHP for interaction.
2. Business Logic Layer: This layer contains the core logic of the system.
It processes user inputs, calculates returns, tracks book availability,
and performs other operations like issuing notices. SQL queries and
stored procedures manage these operations.
3. Data Layer: The data layer consists of the MySQL database, which
stores information about books, members, staff, and transactions.
SQL commands are used to manipulate and retrieve data.

Project Modules
Book Management Module
• Functions: Add new books, update book details, delete books, view books by categories,
check book availability.
• Database Tables: book, book_availability, book_information
Member Management Module
• Functions: Register new members, update member details, view member information,
issue library cards.
• Database Tables: member, library_card
Staff Management Module
• Functions: Add new staff, assign designations, view staff details.
• Database Tables: staff, staff_designation
Book Issue/Return Module
• Functions: Issue books to members, track books issued, return books, check overdue
status.
• Database Tables: book_issued_details
Library Card Module
• Functions: Assign library cards, set expiration dates, add comments/notes to cards.
• Database Tables: library_card
. Report Generation
• Functions: Generate reports for issued books, overdue books, books available, etc.

ENTITY TYPES
1. MEMBERS
2. BOOK
3. STAFF

RELATIONSHIP TYPES
1. ISSUE_CARD
2. ISSUE_NOTICE
3. ISSUE_BOOK
4. GET_DESCRIPTION

IDENTIFICATION
1. Every other entity is uniquely identified by its primary key which can be seen from
the relational schema diagram.
2. The following entities are represented with their primary keys underlined, and
foreign keys by italic style.

• BOOK (book_key, title, author, subject )


• BOOK_INFORMATION ( book_key, isbn, language, binding)
• BOOK_AVAILABILITY ( id, book_key, copies_available, in_stock, rental_eligible,
rented_copies, books_on_loan )
• BOOK_ISSUED_DETAILS ( receipt_no, book_key, issued_book_id, date_issued,
lend_type, grace_period, time_issued_to_return, issued_to_member,
issued_by_staff )
• STAFF ( designation_id , ssn, name)
• STAFF_DESIGNATION ( designation_id, designation_type, designation_power )
• MEMBER ( ssn, phone_no, address, campus_id, comments)
• LIBRARY_CARD ( ssn, expiry_date, notice_comments )

AGGREGATION
1. All entities are aggregation of component attributes as seen from the EER
diagram.
2. Relation types that have member attributes, is also an example aggregation.
SPECIALIZATION / GENERALIZATION
1. The Books have been specialized to in_stock, and on_loan on the basis of its
availability. .
This would be a total disjoint specialization.

2. In_stock is further specialized to rentable or not_rentable on the basis of its


rental_category. This would be a total disjoint specialization.

3. The Staff is classified/ specialized on the basis of its designation. This would be a
partial disjoint specialization.

ASSUMPTIONS
1. We assumed that all books borrowed are kept as loan
2. There might be many number of books that have same isbn.
3. Reference Librarians have the power to access description of books,
and not other designation_staff.
4. Every library card has a notice attached to it.
5. Every Member has a comment attached to her/ his account.
EER DIAGRAM
3

EER-to-RELATIONAL MAPPING

Here, all the primary keys are referenced with an arrow pointed towards itself. All the foreign
keys are depicted by a line pointing straight.
RELATIONAL SCHEMA DIAGRAM
SQL SCHEMA

1. Table structure for table `book`


CREATE TABLE `book` (
`book_key` int(11) NOT NULL,
`title` varchar(200) NOT NULL,
`author` varchar(200) NOT NULL,
`subject` varchar(200) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

2. Table structure for table `book_availability`


CREATE TABLE `book_availability` (
`id` int(11) NOT NULL,
`book_key` int(10) DEFAULT 0,
`copies_available` int(20) NOT NULL,
`in_stock` int(11) NOT NULL,
`rental_eligible` text NOT NULL,
`rented_copies` int(10) NOT NULL,
`books_on_loan` int(10) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
3. Table structure for table `book_information`
CREATE TABLE `book_information` (
`book_key` int(10) DEFAULT 1,
`isbn` int(20) NOT NULL,
`langugae` text NOT NULL,
`binding` text NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

4. Table structure for table `book_issued_details`


CREATE TABLE `book_issued_details` (
`receipt_no` int(10) NOT NULL,
`book_key` int(10) DEFAULT 2,
`issued_book_id` int(10) NOT NULL,
`date_issued` date NOT NULL,
`lend_type` text NOT NULL,
`grace_period` varchar(50) NOT NULL,
`time_issued_to_return` varchar(50) NOT NULL,
`issued_to_member` int(10) DEFAULT 555555555,
`issued_by_staff` int(10) DEFAULT 888888888
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
5. Table structure for table `library_card`
CREATE TABLE `library_card` (
`ssn` int(10) NOT NULL,
`expirty_date` date NOT NULL,
`notice_comments` varchar(500) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

6. Table structure for table `member` CREATE TABLE


`member` (
`ssn` int(10) NOT NULL,
`phone_no` varchar(15) NOT NULL,
`address` varchar(100) NOT NULL,
`campus_id` int(10) NOT NULL,
`comments` varchar(500) NOT NULL
)
ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
7. Table structure for table `staff` CREATE TABLE `staff`
(
`designation_id` int(10) DEFAULT 0,
`ssn` int(10) NOT NULL,
`name` varchar(50) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

8. Table structure for table `staff_designation`


CREATE TABLE `staff_designation` (
`designation_id` int(10) NOT NULL,
`designation_type` text NOT NULL,
`designation_power` int(5) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;

9. Primary Key Structure for all entities


ALTER TABLE `book`
ADD PRIMARY KEY (`book_key`);

ALTER TABLE `book_availability`


ADD PRIMARY KEY (`id`),
ADD UNIQUE KEY `book_key_2` (`book_key`),
ADD KEY `book_key` (`book_key`);

ALTER TABLE `book_information`


ADD PRIMARY KEY (`isbn`),
ADD KEY `book_key` (`book_key`);

ALTER TABLE `book_issued_details`


ADD PRIMARY KEY (`receipt_no`),
ADD KEY `issued_by_staff` (`issued_to_member`),
ADD KEY `issued_by_staff_2` (`issued_by_staff`),
ADD KEY `book_key` (`book_key`);

ALTER TABLE `library_card`


ADD PRIMARY KEY (`ssn`),
ADD KEY `ssn` (`ssn`);

ALTER TABLE `member`


ADD PRIMARY KEY (`ssn`);

ALTER TABLE `staff`


ADD PRIMARY KEY (`ssn`),
ADD KEY `designation_id` (`designation_id`),
ADD KEY `ssn` (`ssn`);

ALTER TABLE `staff_designation`


ADD PRIMARY KEY (`designation_id`),
ADD KEY `designation_id` (`designation_id`);

ALTER TABLE `book_availability`


MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=8;

Foreign Key Structure for all entities


ALTER TABLE `book_availability`
ADD CONSTRAINT `book_availability_ibfk_1` FOREIGN KEY (`book_key`) REFERENCES `book`
(`book_key`) ON DELETE SET NULL ON UPDATE CASCADE;

ALTER TABLE `book_information`


ADD CONSTRAINT `book_information_ibfk_1` FOREIGN KEY (`book_key`) REFERENCES `book`
(`book_key`) ON DELETE SET NULL ON UPDATE CASCADE;

ALTER TABLE `book_issued_details`


ADD CONSTRAINT `book_issued_details_ibfk_1` FOREIGN KEY (`issued_by_staff`) REFERENCES `staff`
(`ssn`) ON DELETE SET NULL ON UPDATE CASCADE,
ADD CONSTRAINT `book_issued_details_ibfk_2` FOREIGN KEY (`book_key`) REFERENCES `book`
(`book_key`) ON DELETE SET NULL ON UPDATE CASCADE,
ADD CONSTRAINT `book_issued_details_ibfk_3` FOREIGN KEY (`issued_to_member`) REFERENCES
`member` (`ssn`) ON DELETE SET NULL ON UPDATE CASCADE;

ALTER TABLE `library_card`


ADD CONSTRAINT `library_card_ibfk_1` FOREIGN KEY (`ssn`) REFERENCES `member` (`ssn`) ON
UPDATE CASCADE;

ALTER TABLE `staff`


ADD CONSTRAINT `staff_ibfk_1` FOREIGN KEY (`designation_id`) REFERENCES `staff_designation`
(`designation_id`) ON DELETE SET NULL ON UPDATE CASCADE;

Styling and UI Enhancement


The user interface is designed to be clean, user-friendly, and responsive. It
incorporates simple forms for book and member management and uses
tables to display data in an organized manner. Enhancements include:
• Responsive Design: Ensures compatibility with both desktop and mobile
devices.
• CSS: Styling for tables, buttons, and forms to improve the visual appeal and
usability.
• Error Handling: Provides clear error messages when invalid data is entered.

Testing and Deployment:


Testing
• Unit Testing: Each module (e.g., book management, member management) is
tested individually to ensure correct functionality.
• Integration Testing: The entire system is tested for seamless data flow
between modules.
• SQL Query Testing: Queries are tested for accuracy in retrieving and updating
data.
• Performance Testing: Ensures the system performs efficiently with multiple
users and large datasets.
Deployment
• Database Setup: The MySQL database is set up on a server, and the schema
is implemented.
• Web Interface Deployment: If a web-based interface is used, the system is
deployed on an Apache server.
• Backup and Restore: Regular backups are scheduled for data integrity.

Learning Outcomes
• Database Design: Gained hands-on experience with database design,
creating tables, defining primary/foreign keys, and writing SQL queries for
complex operations.
• Project Management: Learned to break down a large project into smaller
modules, implement them efficiently, and integrate them into a working
system.
• Testing: Improved skills in testing SQL queries, validating data, and
troubleshooting issues.
• UI Development: Developed an understanding of designing user-friendly
interfaces that cater to both functionality and usability.

Conclusion
The Library Management System project successfully demonstrates the use of
SQL queries in managing books, members, and staff data in a library. The
project aims to automate the traditional library management processes,
improving efficiency and minimizing human errors. It also highlights the
importance of database design, SQL optimization, and system testing in
developing robust applications. Through this project, I have gained valuable
insights into system design, database management, and software
development lifecycle, which will be helpful for my future projects.

You might also like