100% found this document useful (1 vote)
332 views

Library Management System

“Library Management System” is a windows application designed to help users maintain and organize library. Our software is easy to use for both beginners and advanced users. It features a familiar and well thought-out, an attractive user interface, combined with strong searching Insertion and reporting capabilities. The report generation facility of library system helps to get a good idea of which are the books borrowed by the members, makes users possible to generate reports’ hard copy.

Uploaded by

meghait26
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
332 views

Library Management System

“Library Management System” is a windows application designed to help users maintain and organize library. Our software is easy to use for both beginners and advanced users. It features a familiar and well thought-out, an attractive user interface, combined with strong searching Insertion and reporting capabilities. The report generation facility of library system helps to get a good idea of which are the books borrowed by the members, makes users possible to generate reports’ hard copy.

Uploaded by

meghait26
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 73

P

R
Unde
PROJECT
REPORT
er guida
T
L

ance o
Library
of Prof.
yMana
Vinaya
agemen
k Pand
ntSyst
a | Me
tem
egha Kuumari

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

A
Project Report
On
LibraryManagementSystem
Submitted in partial fulfillment of
The requirements for the award of the 7
th
Semester of
BACHELOR OF TECHNOLOGY
IN
Information Technology

By
MEGHAKUMARI(1001210535)

Undertheesteemedguidanceof
Prof.VinayakPanda

DEPARTMMENTOFINFORMATIONTECHNOLOGY
GANDHIINSTITUTEOFENGINEERINGANDTECHNOLOGY
GUNUPUR765022
201314

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

Dep




T
Sys
of
Inf
sub







(Pro
Pr


artmentofI



This is
stem is
the requ
formation
bmitted t
of. Vianayak
oject Super
nformationT

D

to certif
done by
uirements
n Techn
o the dep
k Panda )
rvisor
Technology,
epartm

fy that
y MEGHA
s for the
nology d
partment



LibraryM
GIET,Gunup
mentofI
CER
the proj
A KUMA
award o
during th
as a part


Managemen
pur
nforma
RTIFIC
ject wor
ARI, Regd
of the de
he acade
t of evalu






ntSystem
ationTe
CATE
rk entitle
d. No .100
egree of
emic ye
uation of
(Prof

chnolog
ed Lib
01210535
f Bachelo
ar 2013
f 7
th
Sem
f.(Dr.)PRAG
H.
gy
rary M
in partial
or of Tec
3-14. Th
ester Pro
GNYABAN M
.O.D, IT
Managem
l fulfillm
chnology
his work
oject.
MISHRA)
ment
ment
y in
k is

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur




ACKNOWLEDGEMENT



The completion of this project consists of precious guidance and direction of many people and
hence in order to pay my respect, I would like to acknowledge all of them.

My primary obligation goes to the Gandhi Institute for giving me the golden opportunity to work in
an environment extremely conducive for learning and helping to gain an insight into the actual
working of an organisation.

I am grateful to Prof. Vinayak Panda for making our work interesting and exciting by giving
valuable guidance, encouragement, motivation and concrete support. Despite having a busy
schedule he was always ready to spare time and give innovative technical assistance throughout
the development on the project. Last but not the least I would like to thank my family and friends
whose silent support helped me through the making of the project.

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
ABSTRACT



In this project we have attempted to create an environment where people can keep in contact with
each other on the internet easily. People living at various places in the world can spend some
quality time together exchanging messages.

Our vision is to bring people close even after being located at furthest points on earth. They can sit
together and enjoy exchanging ideas and their views, comments and revive the old times together,
or make new friends and have fun with them.

The world is getting faster day by day, people do not have time to travel to the places where their
loved ones live. Instead, they use communication mediums like telephone, VOIP, emails, letters
and so on to keep in touch. Technology has grown up to the extent that communication constraint
of one-to-one has been replaced by many-to-many.

Creating a social networking site helps people interact with their friends and also learn new things
from people. They can meet new people and acquire information. In short, they open their eyes
and ears to the world around them.

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
TABLE OF CONTENTS

Chapter No. TITLE PAGE No.

1. Introduction
2. System Analysis
2.1 Existing System
2.2 Proposed System
2.3 Feasibility Analysis
3. Configuration
3.1 Hardware Configuration
3.2 Software Configuration
4. System Design and Specification
4.1 High Level Design
4.1.1 Data Flow Diagram
4.1.2 ER Diagram
4.2 Low Level Design
4.2.1 Software Interface
4.3 System Design
4.3.1 Input Design
4.3.2 Output Design
4.3.3 Database Design
5. System Implementation
6. Coding
6.1 Sample Coding
7. System Testing
5.1 Unit Testing
5.2 Integration Testing
8. Conclusion


LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
INTRODUCTION

The project titled Library Management System is Library management software for
monitoring and controlling the transactions in a library .The project Library Management
System is developed in java, which mainly focuses on basic operations in a library like
adding new member, new books, and updating new information, searching books and
members and facility to borrow and return books.

Library Management System is a windows application written for Windows
operating systems, designed to help users maintain and organize library. Our software is
easy to use for both beginners and advanced users. It features a familiar and well thought-
out, an attractive user interface, combined with strong searching Insertion and reporting
capabilities. The report generation facility of library system helps to get a good idea of which
are the books borrowed by the members, makes users possible to generate reports hard
copy.
The software Library Management System has four main modules.

Insertion to Database Module User friendly input screen
Extracting from Database module Attractive Output Screen
Report Generation module borrowed book list & Available book list
Search Facility system search for books and members
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
SYSTEMANALYSIS
EXISTING SYSTEM:
System Analysis is a detailed study of the various operations performed by a
system and their relationships within and outside of the system. Here the key question is-
what all problems exist in the present system? What must be done to solve the problem?
Analysis begins when a user or manager begins a study of the program using existing
system.
During analysis, data collected on the various files, decision points and
transactions handled by the present system. The commonly used tools in the system are
Data Flow Diagram, interviews, etc. Training, experience and common sense are required
for collection of relevant information needed to develop the system. The success of the
system depends largely on how clearly the problem is defined, thoroughly investigated and
properly carried out through the choice of solution. A good analysis model should provide
not only the mechanisms of problem understanding but also the frame work of the
solution. Thus it should be studied thoroughly by collecting data about the system. Then
the proposed system should be analyzed thoroughly in accordance with the needs.
System analysis can be categorized into four parts.
System planning and initial investigation
Information Gathering
Applying analysis tools for structured analysis
Feasibility study
Cost/ Benefit analysis.
In our existing system all the transaction of books are done manually, So taking more time
for a transaction like borrowing a book or returning a book and also for searching of members and
books. Another major disadvantage is that to preparing the list of books borrowed and the
available books in the library will take more time, currently it is doing as a one day process for
verifying all records. So after conducting the feasibility study we decided to make the manual
Library management system to be computerized.

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
PROPOSED SYSTEM
Proposed system is an automated Library Management System. Through our software
user can add members, add books, search members, search books, update information, edit
information, borrow and return books in quick time. Our proposed system has the following
advantages.
User friendly interface
Fast access to database
Less error
More Storage Capacity
Search facility
Look and Feel Environment
Quick transaction
All the manual difficulties in managing the Library have been rectified by implementing
computerization.















LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
FEASIBILITY ANALYSIS
Whatever we think need not be feasible .It is wise to think about the feasibility of any
problem we undertake. Feasibility is the study of impact, which happens in the organization by the
development of a system. The impact can be either positive or negative. When the positives
nominate the negatives, then the system is considered feasible. Here the feasibility study can be
performed in two ways such as technical feasibility and Economical Feasibility.

Technical Feasibility:
We can strongly says that it is technically feasible, since there will not be much difficulty in
getting required resources for the development and maintaining the system as well. All the
resources needed for the development of the software as well as the maintenance of the same is
available in the organization here we are utilizing the resources which are available already.
Economical Feasibility:
Development of this application is highly economically feasible .The organization needed not
spend much m one for the development of t he system already available. The only thing is to be
done is making an environment for the development with an effective supervision. I f we are doing
so , we can attain the maximum usability of the corresponding resources .Even after the
development , the organization will not be in a condition to invest more in t he organization .There
fore , the system is economically feasible.

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
HARDWARE CONFIGURATION
Processor : Pentium III 630MHz
RAM : 512 MB
Hard Disk : 30 GB
Monitor : 14 Color monitor
Key Board : 122 Keys






LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
SOFTWARE CONFIGURATION

Operating System : Windows 98,
Windows XP,
Windows Vista,
Windows 7.
Language : Java 2 Runtime Environment
Database : MS Access 2007

















Dep
DA

artmentofI
ATA FLOW
nformationT
W DIAG
Technology,
System
RAM
LibraryM
GIET,Gunup
m Desig
Managemen
pur
gn and
ntSystem
Specific cation
Dep

artmentofInformationT Technology,

LibraryM
GIET,Gunup
Managemen
pur

ntSystem

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
E R DIAGRAM
Book
Book name Return date
Reserved Flag Book issue to
Book id
Status Book return
Book Author
Book Category
Reserve By
Issue date
Usernpasswd
Password User Id


LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

userdata
User name NumberOfBooksTaken User Id
Gender
Department Course
Semester
adminlog
Password User Id



LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

userdata
User name
NumberOfBooksTaken User Id
Gender
Department
Course
Semester
Librari an
Password
User Id
Books
Return date
Book Id
Issue date
Book Author
Reserved Flag
Book issue to
Status
usernpass
Password
Book Category
Book return
Reserve By
Issue
Borrow by
User Id
Access to


DepartmentofInformationT
S
Technology,
SOFT
LibraryM
GIET,Gunup
TWAR
We
L
Managemen
pur
RE IN
elcome P
Login Pag

ntSystem
NTERF
Page
ge
FACEE

DepartmentofInformationT Technology,
LibraryM
GIET,Gunup
Admi
Staf
Managemen
pur

in Login

ff Login P


ntSystem
n Page
Page


DepartmentofInformationT Technology,
LibraryM
GIET,Gunup
Membe
All Bo
Managemen
pur

ers Tab
ook Deta


ntSystem
ble Page
il Page


DepartmentofInformationT Technology,
A
LibraryM
GIET,Gunup
Sea
Adminst
Managemen
pur

arch Boo
rator Lo
ntSystem
oks
ogin Pagge


DepartmentofInformationT Technology,
LibraryM
GIET,Gunup
Ad
A
Managemen
pur

d New U

Add Boo



ntSystem
User
ok
Dep

artmentofInformationT Technology,
LibraryM
GIET,Gunup
Staf
Managemen
pur

ff Login P





ntSystem
Page

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

SYSTEM DESIGN
INPUT DESIGN
Input design is the process of converting user-oriented input to a computer based format.
Input design is a part of overall system design, which requires very careful attention .Often the
collection of input data is the most expensive part of the system. The main objectives of the input
design are
1. Produce cost effective method of input
2. Achieve highest possible level of accuracy
3. Ensure that the input is acceptable to and understood by the staff.
OUTPUT DESIGN
Outputs from computer systems are required primarily to communicate the results of
processing to users. They are also used to provide a permanent copy of these result for latter
consultation .Computer output is the most important and direct source of information to the users.
Designing computer output should proceed in an organized well throughout the manner. The right
output must be available for the people who find the system easy o use. The outputs have been
defined during the logical design stage. If not, they should defined at the beginning of the output
designing terms of types of output connect, format, response etc,
All screens are informative and interactive in such a way that the user can full fill his
requirements through asking queries.







LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
DATABASE DESIGN
The general theme behind a database is to handle information as an integrated
whole. A database is a collection of interrelated data stored with minimum redundancy to serve
many users quickly and effectively. After designing input and output, the analyst must
concentrate on database design or how data should be organized around user requirements.
The general objective is to make information access, easy quick, inexpensive and flexible for
other users. During database design the following objectives are concerned:-

Controlled Redundancy
Data independence
Accurate and integrating
More information at low cost
Recovery from failure
Privacy and security
Performance
Ease of learning and use





LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
TABLES USED
TABLE NAME: adminlog
FieldName DataType Description
Userid Text PrimaryKey
Password Text

TABLE NAME: books
FieldName DataType Description
BookId Text PrimaryKey
Bookname Text
BookAuthor Text
BookCategory Text
Bookissueto Text
Status Number
Bookreturn Number
ReservedFlag Number
ReserveBy Text
Issuedate Date
Returndate Date









LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
TABLE NAME: usernpasswd

FieldName DataType Description
UserId Text PrimaryKey
Password Text

TABLE NAME: userdata



Field Name Data Type Description
User Id Text Primary Key
User name Text -
Gender Text -
Department Text -
Course Text -
Semester Text -
NumberOfBooksTaken Text -



LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
SYSTEM IMPLEMENTATION

Implementation is the stage in the project where the theoretical design is turned into a
working system. The implementation phase constructs, installs and operates the new system. The
most crucial stage in achieving a new successful system is that it will work efficiently and
effectively.
There are several activities involved while implementing a new project they are
End user training
End user Education
Training on the application software
System Design
Parallel Run And To New System
Post implementation Review
END USER TRAINING:
The successful implementation of the new system will purely upon the involvement of the officers
working in that department. The officers will be imparted the necessary training on the new
technology.
END USER EDUCATION:
The education of the end user start after the implementation and testing is over. When the
system is found to be more difficult to understand and complex, more effort is put to educate the
end used to make them aware of the system, giving them lectures about the new system and
providing them necessary documents and materials about how the system can do this.

TRAINING OF APPLICATION SOFTWARE:
After providing the necessary basic training on the computer awareness, the users will have
to be trained upon the new system such as the screen flows and screen design type of help on the
screen, type of errors while entering the data , the corresponding validation check at each entry
and the way to correct the data entered. It should then cover information needed by the specific
user or group to use the system.

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
POST IMPLEMENTATION VIEW:
The department is planning a method to know the states of the past implementation
process. For that regular meeting will be arranged by the concerned officers about the
implementation problem and success










LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
CODING
ADMIN LOGIN PAGE SAMPLE CODE

/*NewAccount.java*/
importjava.awt.*;
importjava.awt.event.*;
importjavax.swing.*;
importjava.sql.*;
importjavax.swing.table.*;
publicclassadminlogextendsjavax.swing.JFrame{

/**CreatesnewformNewAccount*/
publicadminlog(){
initComponents();
}

/**Thismethodiscalledfromwithintheconstructorto
initializetheform*/

privatevoidinitComponents(){
jLabel1=newjavax.swing.JLabel();
jLabel2=newjavax.swing.JLabel();
jLabel6=newjavax.swing.JLabel();
userid=newjavax.swing.JTextField();
password=newjavax.swing.JPasswordField();
update=newjavax.swing.JButton();
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
finish=newjavax.swing.JButton();

getContentPane().setLayout(null);

//setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);

setTitle("Adminlog");
jLabel1.setFont(newjava.awt.Font("Tahoma",1,14));
jLabel1.setForeground(newjava.awt.Color(102,0,0));
jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
jLabel1.setText("USERID:");
getContentPane().add(jLabel1);
jLabel1.setBounds(20,60,120,20);

jLabel2.setFont(newjava.awt.Font("Tahoma",1,14));
jLabel2.setForeground(newjava.awt.Color(102,0,0));
jLabel2.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
jLabel2.setText("PASSWORD:");
getContentPane().add(jLabel2);
jLabel2.setBounds(20,90,120,20);

jLabel6.setFont(newjava.awt.Font("Tahoma",1,18));
jLabel6.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
jLabel6.setText("ADMINISTRATORLOGIN");
getContentPane().add(jLabel6);
jLabel6.setBounds(50,20,300,20);

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
userid.setFont(newjava.awt.Font("Tahoma",0,14));
getContentPane().add(userid);
userid.setBounds(170,60,130,20);

password.setFont(newjava.awt.Font("Tahoma",0,14));
getContentPane().add(password);
password.setBounds(170,90,130,20);

update.setText("LOGIN");
update.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{

if(userid.getText().equals(""))
{
JOptionPane.showMessageDialog((Component)null,
"PleaseEnter\nloginandpassword","LoginError",
JOptionPane.INFORMATION_MESSAGE);
}
else{
//setVisible(false);
//AdminPageap=newAdminPage();
verifyAdmLogin();

}
}
});
update.setToolTipText("CLICKTOLOGIN");
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
getContentPane().add(update);
update.setBounds(340,60,80,30);

finish.setText("EXIT");
finish.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
setVisible(false);
LogPagellp=newLogPage();
}
});
finish.setToolTipText("CLICKTOEXIT");
getContentPane().add(finish);
finish.setBounds(340,100,80,30);

pack();
setSize(500,200);
setVisible(true);
setLocation(200,200);
}

/**
*@paramargsthecommandlinearguments
*/
publicstaticvoidmain(Stringargs[]){
adminlogad=newadminlog();
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
}

privatejavax.swing.JButtonfinish;
privatejavax.swing.JLabeljLabel1;
privatejavax.swing.JLabeljLabel2;
privatejavax.swing.JLabeljLabel6;
privatejavax.swing.JPasswordFieldpassword;
privatejavax.swing.JButtonupdate;
privatejavax.swing.JTextFielduserid;
//Endofvariablesdeclaration

//*******************************************verifyadmin
login**************************************************
voidverifyAdmLogin()
{
Connectioncon=null;
Stringurl="jdbc:odbc:GIET";
Statementst=null;

try
{

Stringval1=userid.getText();
val1=val1.trim();
Stringval2=(String)password.getText();
val2=val2.trim();
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur



Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");

con=DriverManager.getConnection(url);

st=con.createStatement();


ResultSetrs=st.executeQuery("SelectPasswdfromadminlog
whereUserId='"+val1+"'");

while(rs.next()){
Stringuser=rs.getString(1);
System.out.println(user);

booleanb=user.equals(val2);



if(b)
{
setVisible(false);
AdminPageaaa=newAdminPage();
}
else
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
{




JOptionPane.showMessageDialog((Component)null,
"Invalidpassword.\nPleaseenteragain.","LoginError",
JOptionPane.INFORMATION_MESSAGE);
setVisible(false);
adminlogalog=newadminlog();


}

}



}
catch(SQLExceptionex)
{
System.out.println("Unabletoaccessthedatabase");
}
catch(ClassNotFoundExceptionex)
{
System.out.println("Classnotfound");
}
catch(Exceptionex)
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
{
System.out.println("Exceptionraisedis:"+ex);
}
finally{
con=null;
}
}


LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
STAFFLOGINPAGESAMPLECODE
/*NewAccount.java*/
importjava.awt.*;
importjava.awt.event.*;
importjavax.swing.*;
importjava.sql.*;
importjavax.swing.table.*;
publicclassstafflogextendsjavax.swing.JFrame{

/**CreatesnewformNewAccount*/
publicstafflog(){
initComponents();
}

privatevoidinitComponents(){
jLabel1=newjavax.swing.JLabel();
jLabel2=newjavax.swing.JLabel();
jLabel6=newjavax.swing.JLabel();
userid=newjavax.swing.JTextField();
password=newjavax.swing.JPasswordField();
update=newjavax.swing.JButton();
finish=newjavax.swing.JButton();

getContentPane().setLayout(null);

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
setTitle("STAFFLOG");
jLabel1.setFont(newjava.awt.Font("Tahoma",1,14));
jLabel1.setForeground(newjava.awt.Color(102,0,0));
jLabel1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
jLabel1.setText("USERID:");
getContentPane().add(jLabel1);
jLabel1.setBounds(20,60,120,20);

jLabel2.setFont(newjava.awt.Font("Tahoma",1,14));
jLabel2.setForeground(newjava.awt.Color(102,0,0));
jLabel2.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
jLabel2.setText("PASSWORD:");
getContentPane().add(jLabel2);
jLabel2.setBounds(20,90,120,20);

jLabel6.setFont(newjava.awt.Font("Tahoma",1,18));
jLabel6.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
jLabel6.setText("STAFFLOGIN");
getContentPane().add(jLabel6);
jLabel6.setBounds(50,20,300,20);

userid.setFont(newjava.awt.Font("Tahoma",0,14));
getContentPane().add(userid);
userid.setBounds(170,60,130,20);

password.setFont(newjava.awt.Font("Tahoma",0,14));
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
getContentPane().add(password);
password.setBounds(170,90,130,20);

update.setText("LOGIN");
update.setToolTipText("CLICKTOLOGIN");
update.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
if(userid.getText().equals(""))
{
JOptionPane.showMessageDialog((Component)null,"Plese
Enter\nloginandpassword","LoginError",JOptionPane.INFORMATION_MESSAGE);
}
else{

verifystaffLogin();

}

}

});


getContentPane().add(update);
update.setBounds(340,60,80,30);

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
finish.setText("EXIT");
finish.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
setVisible(false);
LogPagellp=newLogPage();

}

});
finish.setToolTipText("CLICKTOEXIT");
getContentPane().add(finish);
finish.setBounds(340,100,80,30);

pack();
setSize(500,200);
setVisible(true);
setLocation(200,200);
}
publicstaticvoidmain(Stringargs[]){
stafflogad=newstafflog();
}

//Variablesdeclarationdonotmodify
privatejavax.swing.JButtonfinish;
privatejavax.swing.JLabeljLabel1;
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
privatejavax.swing.JLabeljLabel2;
privatejavax.swing.JLabeljLabel6;
privatejavax.swing.JPasswordFieldpassword;
privatejavax.swing.JButtonupdate;
privatejavax.swing.JTextFielduserid;
//Endofvariablesdeclaration

voidverifystaffLogin()
{
Connectioncon=null;
Stringurl="jdbc:odbc:GIET";
Statementst=null;

try
{

Stringval1=userid.getText();
val1=val1.trim();
Stringval2=(String)password.getText();
val2=val2.trim();



Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");

con=DriverManager.getConnection(url);
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

st=con.createStatement();


ResultSetrs=st.executeQuery("SelectPasswdfromadminlog
whereUserId='"+val1+"'");

while(rs.next()){
Stringuser=rs.getString(1);
System.out.println(user);

booleanb=user.equals(val2);



if(b)
{
setVisible(false);
LibrarianPageaaa=newLibrarianPage();
}
else
{




LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
JOptionPane.showMessageDialog((Component)null,
"InvalidLoginname/password.Pleaseenteragain.","LoginError",
JOptionPane.INFORMATION_MESSAGE);


}

}



}
catch(SQLExceptionex)
{
System.out.println("Unabletoaccessthedatabase");
}
catch(ClassNotFoundExceptionex)
{
System.out.println("Classnotfound");
}
catch(Exceptionex)
{
System.out.println("Exceptionraisedis:"+ex);
}
finally{
con=null;
}
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
}


}

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
LIBRARIANPAGESAMPLECODE
//AdminPage.java

importjava.awt.*;
importjava.awt.event.*;
importjavax.swing.*;
importjava.sql.*;
importjavax.swing.table.*;
publicclassLibrarianPageextendsjavax.swing.JFrame{

/**CreatesnewformAdminPage*/
publicLibrarianPage(){
initComponents();
}

privatevoidinitComponents(){
heading=newjavax.swing.JLabel();
heading1=newjavax.swing.JLabel();
heading3=newjavax.swing.JLabel();
heading5=newjavax.swing.JLabel();
issuebook=newjavax.swing.JButton();
addbooks=newjavax.swing.JButton();
deletebooks=newjavax.swing.JButton();
reserve=newjavax.swing.JButton();
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
logout=newjavax.swing.JButton();
heading4=newjavax.swing.JLabel();
heading6=newjavax.swing.JLabel();
heading7=newjavax.swing.JLabel();
returnbook=newjavax.swing.JButton();

getContentPane().setLayout(null);

setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle("LIBRARIANPAGE");
setForeground(newjava.awt.Color(254,215,3));
heading.setFont(newjava.awt.Font("Tahoma",3,18));
heading.setForeground(newjava.awt.Color(102,0,0));
heading.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
heading.setText("CENTERALLIBRARYGIETGUNUPUR.");
getContentPane().add(heading);
heading.setBounds(380,20,310,30);

heading1.setFont(newjava.awt.Font("Tahoma",3,14));
heading1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
heading1.setText("ISSUEBOOK=>");
getContentPane().add(heading1);
heading1.setBounds(110,160,210,30);

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
heading3.setFont(newjava.awt.Font("Tahoma",3,14));
heading3.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
heading3.setText("DELETEBOOKDETAIL=>");
getContentPane().add(heading3);
heading3.setBounds(120,380,210,30);

heading5.setFont(newjava.awt.Font("Tahoma",3,14));
heading5.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
heading5.setText("RESERVEBOOK=>");
getContentPane().add(heading5);
heading5.setBounds(130,270,210,30);

issuebook.setText("ISSUE");
issuebook.setToolTipText("Clicktocreatenewaccount");
issuebook.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
issueiss=newissue();
}
});
getContentPane().add(issuebook);
issuebook.setBounds(380,160,120,30);

addbooks.setText("ADDNEWBOOK");
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
addbooks.setToolTipText("addnewboooks");
addbooks.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
//setVisible(false);
NewBooknb=newNewBook();

}
});
getContentPane().add(addbooks);
addbooks.setBounds(390,330,120,30);

deletebooks.setText("DELETEBOOK");
deletebooks.setToolTipText("Deletebook");
deletebooks.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
//setVisible(false);
DeleteBookdb=newDeleteBook();

}
});
getContentPane().add(deletebooks);
deletebooks.setBounds(390,380,120,30);
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

reserve.setText("RESERVE");
reserve.setToolTipText("reservebook");
reserve.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
reservebookrb=newreservebook();

}
});
reserve.setFocusPainted(false);
getContentPane().add(reserve);
reserve.setBounds(380,270,120,30);

logout.setFont(newjava.awt.Font("Tahoma",1,14));
logout.setText("LOGOUT");
logout.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
setVisible(false);
LogPagelp=newLogPage();

}
});
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
getContentPane().add(logout);
logout.setBounds(550,450,100,50);

heading4.setFont(newjava.awt.Font("Tahoma",3,18));
heading4.setForeground(newjava.awt.Color(0,102,102));
heading4.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
heading4.setText("STAFFPAGE");
getContentPane().add(heading4);
heading4.setBounds(30,20,310,30);

heading6.setFont(newjava.awt.Font("Tahoma",3,14));
heading6.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
heading6.setText("ADDNEWBOOKS=>");
getContentPane().add(heading6);
heading6.setBounds(120,330,210,30);

heading7.setFont(newjava.awt.Font("Tahoma",3,14));
heading7.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
heading7.setText("RETURNBOOK=>");
getContentPane().add(heading7);
heading7.setBounds(120,220,210,30);

returnbook.setText("RETURN");
returnbook.setToolTipText("clicktoreturnbook");
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

}
returnbook.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
returnbrrr=newreturnb();

}
});
getContentPane().add(returnbook);
returnbook.setBounds(380,220,120,30);

pack();
setSize(800,600);
setLocation(50,50);
setVisible(true);

publicstaticvoidmain(Stringargs[]){
LibrarianPagelp=newLibrarianPage();
}

//Variablesdeclarationdonotmodify
privatejavax.swing.JButtonaddbooks;
privatejavax.swing.JButtondeletebooks;
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
privatejavax.swing.JLabelheading;
privatejavax.swing.JLabelheading1;
privatejavax.swing.JLabelheading3;
privatejavax.swing.JLabelheading4;
privatejavax.swing.JLabelheading5;
privatejavax.swing.JLabelheading6;
privatejavax.swing.JLabelheading7;
privatejavax.swing.JButtonissuebook;
privatejavax.swing.JButtonlogout;
privatejavax.swing.JButtonreserve;
privatejavax.swing.JButtonreturnbook;
//Endofvariablesdeclaration


LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
LEASTBOOKPAGEOFSAMPLECODE
importjava.awt.*;
importjava.awt.event.*;

importjavax.swing.*;

importjava.sql.*;

publicclassListBookextendsJFrame{

privateJPanelpBook=newJPanel();
privateJTabletable;
privateJScrollPanejsp;
privateObjectdata1[][];
privateContainerc;
privateJButtonok;
introw=0;
publicListBook(){

pBook.setLayout(null);
ok=newJButton("ok");
ok.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
listbok();
}

});
ok.setBounds(25,175,125,25);
pBook.add(ok);

getContentPane().add(pBook,BorderLayout.CENTER);
setSize(400,400);
//setVisible(true);
setLocation(200,200);



}


publicvoidlistbok(){


Connectioncon=null;
Stringurl="jdbc:odbc:GIET";
Statementst=null;
try{
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
con=DriverManager.getConnection(url);
st=con.createStatement();

Stringq,bavl,bisr;


ResultSetrss=st.executeQuery("SELECT*FROMbk");
while(rss.next()){
row++;
}
System.out.println(row);

data1=newObject[row][6];
System.out.println("hai");
Object[]Colheads={"Bookid","bookname","book
auther","bookcategory","issuedto","status"};
ResultSetrs=st.executeQuery("SELECT*FROMbk");
//ExecutingtheQuery.

for(inti1=0;i1<row;i1++)
{
rs.next();
for(intj1=0;j1<6;j1++)
{
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

data1[i1][j1]=rs.getString(j1+1);

}
System.out.println();

}
table=newJTable(data1,Colheads);
int
v=ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED;
int
h=ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED;

jsp=newJScrollPane(table,v,h);
TableDisptd=newTableDisp(table);


}
catch(Exceptionsqlex){


}

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
}



publicstaticvoidmain(String[]args){

ListBooklmm=newListBook();


}
}
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
LISTMEMBERPAGESAMPLECODE
importjava.awt.*;
importjava.awt.event.*;

importjavax.swing.*;

importjava.sql.*;

publicclassListMembersextendsJFrame{

privateJPanelpBook=newJPanel();
privateJTabletable;
privateJScrollPanejsp;
privateObjectdata1[][];
privateContainerc;
privateJButtonok;
introw=0;
publicListMembers(){

pBook.setLayout(null);
ok=newJButton("ok");
ok.addActionListener(newActionListener(){
publicvoidactionPerformed(ActionEventevt)
{
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
listmem();
}

});
ok.setBounds(25,175,125,25);
pBook.add(ok);

getContentPane().add(pBook,BorderLayout.CENTER);
setSize(400,400);
setVisible(true);
setLocation(200,200);



}


publicvoidlistmem(){


Connectioncon=null;
Stringurl="jdbc:odbc:GIET";
Statementst=null;
try{
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
con=DriverManager.getConnection(url);
st=con.createStatement();

Stringq,bavl,bisr;


ResultSetrss=st.executeQuery("SELECT*FROMuserdata");
while(rss.next()){
row++;
}
System.out.println(row);

data1=newObject[row][7];
System.out.println("hai");
Object[]
Colheads={"useridno","username","gender","department","course","semester",
"NO_BOOK_TAKEN"};
ResultSetrs=st.executeQuery("SELECT*FROMuserdata");
//ExecutingtheQuery.

for(inti1=0;i1<row;i1++)
{
rs.next();
for(intj1=0;j1<7;j1++)
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
{

data1[i1][j1]=rs.getString(j1+1);

}
System.out.println();

}
table=newJTable(data1,Colheads);
int
v=ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED;
int
h=ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED;

jsp=newJScrollPane(table,v,h);
TableDisptd=newTableDisp(table);


}
catch(Exceptionsqlex){

// JOptionPane.showMessageDialog(this,"Some
probFound.");

}
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

}



publicstaticvoidmain(String[]args){

ListMemberslmm=newListMembers();


}
}

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
L

JDBC-ODBC Connection Code:


Connection con=null;
String url="jdbc:odbc:GIET";
Statement st=null;
Try
{
Class.forName("sun.jdbc.odbc.J dbcOdbcDriver");
con=DriverManager.getConnection(url);
st =con.createStatement();
String q,bavl,bisr;
ResultSet rss=st.executeQuery("SELECT * FROM bk ");
}
Creating Interface Sample Code:
public LogPage()
{ initComponents(); }
private void initComponents() {
heading =new javax.swing.J Label();
heading1 =new javax.swing.J Label();
dt =new javax.swing.J Label();
dtt =new javax.swing.J Label();
heading2 =new javax.swing.J Label();
heading3 =new javax.swing.J Label();
adminlog =new javax.swing.J Button();
liblog =new javax.swing.J Button();
userlog =new javax.swing.J Button();
jButton1 =new javax.swing.J Button();
bookdetail =new javax.swing.J Button();
userdetail =new javax.swing.J Button();
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
search =new javax.swing.J Button();
getContentPane().setLayout(null);
setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
setTitle("ADMINISTRATOR PAGE");
setForeground(new java.awt.Color(254, 215, 3));
heading.setFont(new java.awt.Font("Arial", 3, 18));
heading.setForeground(new java.awt.Color(102, 0, 0));
heading.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
heading.setText("CENTERAL LIBRARY GIET GUNUPUR.");
getContentPane().add(heading);
heading.setBounds(380, 20, 410, 30);
heading1.setFont(new java.awt.Font("Arial", 3, 14));
heading1.setHorizontalAlignment(javax.swing.SwingConstants.RIGHT);
heading1.setText("ADMINISTRATOR LOGIN:");
getContentPane().add(heading1);
heading1.setBounds(110, 180, 210, 30);
dt.setFont(new java.awt.Font("Arial", 3,24));
dt.setText("Date :");
getContentPane().add(dt);
dt.setBounds(380,60, 110, 30);









LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur


Form Splash Code
import javax.swing.*;
import java.awt.*;
public class FrmSplash extends J Window implements Runnable
{
public void run()
{
J Label SplashLabel =new J Label(new ImageIcon("Image005.jpg"));
Dimension screen =Toolkit.getDefaultToolkit().getScreenSize();
getContentPane().add(SplashLabel,BorderLayout.CENTER);
setSize(890,600);
setLocation((screen.width - 0)/5,((screen.height-0)/9));
show();
}
}










LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

SOFTWARE TESTING
Is the menu bar displayed in the appropriate contested some system related features
included either in menus or tools? Do pull Down menu operation and Tool-bars work properly?
Are all menu function and pull down sub function properly listed ?; Is it possible to invoke each
menu function using a logical assumptions that if all parts of the system are correct, the goal will
be successfully achieved .? In adequate testing or non-testing will leads to errors that may appear
few months later.
This create two problem
1. Time delay between the cause and appearance of the problem.
2. The effect of the system errors on files and records within the system
The purpose of the system testing is to consider all the likely variations to which it will be
suggested and push the systems to limits.
The testing process focuses on the logical intervals of the software ensuring that all
statements have been tested and on functional interval is conducting tests to uncover errors and
ensure that defined input will produce actual results that agree with the required results. Program
level testing, modules level testing integrated and carried out.
There are two major type of testing they are
1) Unit Testing.
2) Integration Testing.
UNIT TESTING
unit testing is a method by which individual units of source code, sets of one or more computer
program modules together with associated control data, usage procedures, and operating
procedures, are tested to determine if they are fit for use, Intuitively, one can view a unit as the
smallest testable part of an application. In procedural programming a unit could be an entire
module but is more commonly an individual function or procedure. In object-oriented programming
a unit is often an entire interface, such as a class, but could be an individual method. Unit tests are
created by programmers or occasionally by white box testers during the development process.
Ideally, each test case is independent from the others: substitutes like method stubs, mock
objects, fakes and test harnesses can be used to assist testing a module in isolation. Unit tests are
LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur
typically written and run by software developers to ensure that code meets its design and behaves
as intended.
INTEGRATION TESTING
Integration testing is the testing process in software testing to verify that when two or more
modules are interact and produced result satisfies with its original functional requirement or not.
Integrated testing is fall in Black box testing. Integrated testing will start after completion of unit
testing.
Integration testing finds the bugs that occur when two or more models integrated. Main
purpose of Integration testing is to identifying the functional, requirement and performance level
bugs. When modules not integrated, they perform as per requirement but when they integrated,
functional, requirement and performance related issues will occurs due to the integration



LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur


CONCLUSION

Our project is only a humble venture to satisfy the needs in a library. Several user
friendly coding have also adopted. This package shall prove to be a powerful package in
satisfying all the requirements of the organization.

Yes there is always some field for improvement and we looking forward to add those
Improvement and make this application more user friendly and more efficient.
The objective of software planning is to provide a frame work that enables the
Administrator to make reasonable estimates made within a limited time frame at the beginning
of the software project and should be updated regularly as the project progresses.

LibraryManagementSystem
DepartmentofInformationTechnology,GIET,Gunupur

BIBLIOGRAPHY

1) http://www.java2s.com/
2) http://www.javaworld.com/javaworld/jw-01-1998/jw-01-bookreview.html
3) Database Programming with J DBC and J ava by O'Reilly
4) Head First J ava 2nd Edition
5) http://java.sun.com/javase/technologies/desktop/

You might also like