0% found this document useful (0 votes)
25 views53 pages

Development of A Library Management Syst

Rrsarch

Uploaded by

menber988
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)
25 views53 pages

Development of A Library Management Syst

Rrsarch

Uploaded by

menber988
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/ 53

Development of a Library Management

System

by

M d . R ezau l H asan

R o ll N o . D F 0 1 3 1 0 4 3

•.
'

S essio n : 2 0 0 1 -2 0 0 2

•• In stitu te o f In fo rm atio n an d C o m m u n icatio n T ech n o lo g y (n C T )

B an g lad esh U n iv ersity o f E n g in eerin g an d T ech n o lo g y

D h ak a-lO O O , B an g lad esh


Development of a Library Management
System

by

M d. R ezaul H asan

R o ll N o . D F 0 1 3 1 0 4 3

S e s s io n : 2 0 0 1 -2 0 0 2

I n s titu te o f I n f o r m a tio n a n d C o m m u n ic a tio n T e c h n o lo g y (IIC T )

B a n g la d e s h U n iv e r s ity o f E n g in e e r in g a n d T e c h n o lo g y

D h a k a - lO O O , B a n g la d e s h

111111111l1li/111111111111111/1111
} #98296#
Development of a Library Management
System

by

M d. R czaul H asan

R o ll N o . D F 0 1 3 1 0 4 3

A p ro je c t re p o rt s u b m itte d in p a rtia l fu lfillm e n t o f th e re q u ire m e n t fo r th e P o s t

G ra d u a te D ip lo m a in In fo rm a tio n a n d C o m m u n ic a tio n T e c h n o lo g y (P G D lC T )

" P ro je c t S u p e rv is o r

Md. Saiful Islam


A s s is ta n t P ro fe s s o r

In s titu te o f In fo rm a tio n a n d C o m m u n ic a tio n T e c h n o lo g y (!lC T )

B a n g la d e s h U n iv e rs ity o f E n g in e e rin g a n d T e c h n o lo g y

, S e s s io n : 2 0 0 1 -2 0 0 2
.}

In s titu te o fln fo rm a tio n a n d C o m m u n ic a tio n T e c h n o lo g y (IIC T )

B a n g la d e s h U n iv e rs ity o f E n g in e e rin g a n d T e c h n o lo g y

D h a k a -IO O O , B a n g la d e s h .

-'
CERTIFICATE

T h is p ro ject titled "D ev elo p m en t o f a L ib rary M an ag em en t S y stem ", su b m itted by

M d . R ezau l H asan , R o ll N o : D F O 1 3 1 0 4 3 , sessio n : 2 0 0 1 -2 0 0 2 , h as b een accep ted as

satisfacto ry in p artial fu lfillm en t o f th e req u irem en ts fo r th e P o stg rad u ate D ip lo m a in

In fo rm atio n an d C o m m u n icatio n T ech n o lo g y (P G D IC T ) in th e In stitu te of

In fo rm atio n & C o m m u n icatio n T ech n o lo g y , SUET.

B O A R D O F E X A M IN A R S

M d . S a ifu lls la m
C h a irm a n a n d
A s s is ta n t P ro fe s s o r
S u p e rv is o r
In s titu te o f In fo rm a tio n & C o m m u n ic a tio n T e c h n o lo g y (IIC T )

B U E T , D h a k a -1 0 ,B a n g la d e s h .

D r. S .M . L u tfu l K a b ir

P ro fe s s o r

D ire c to r

In s titu te o f In fo rm a tio n & C o m m u n ic a tio n T e c h n o lo g y (IIC T )


M em b er
B U E T , D h a k a -1 0 0 0 , B a n g la d e s h .

\
~ ----= = = = -
~ ra N a th M o n d a l

A s s o c ia te P ro fe s s o r
M em b er
A s s o c ia te D ire c to r (A c a d e m ic )

In s titu te o f In fo rm a tio n & C o m m u n ic a tio n T e c h n o lo g y (IIC T )

B U E T , D h a k a -1 0 0 0 , B a n g la d e s h .

-I-
Declaration

This is declared that this work entitled "Development of a Library Management

System" has been done by the author under supervision of Mr. Md. Saiful Islam,

Assistant Professor, Institute of Information & Communication Technology, SUET,

Dhaka. This is also declared that this or any part of it has not been submitted
elsewhere for the award of any degree or diploma.

Md. Saiful Islam Md. Rezaul Hasan


Countersigned by the Supervisor Signature of the Candidate

- II -
ABSTRACT

The impact of the revolution in information technology on the academic community is


assessed. Libraries playa vital part here. In the context of libraries it application can
be justified only if the users of the library and information service and their
informational needs warrant this. This project is undertaken to develop a system that
can be used to manage library resources efficiently and effectively. The developed
software has been designed with the assistance of professional librarians incorporating
their requirements for a flexible and powerful tool for managing and processing
library resources.

).

-III-
ACKNOWLEDGEMENT

The author acknowledges his sincere gratitude and thanks to Mr. Md. Saiful Islam,

Assistant Professor, Institute of Information and Communication Technology (IICT),

BUET for his constant guidance, suggestions and invaluable assistance during the

entire length of this project. His encouragement and motivation helped the author to

complete the task.

The author is greatly indebted Prof. S. M. Lutful Kabir, Director of the Institute of

Information and Communication Technology (IICT), B UET to provide every

facilities and cordial assistance throughout the project.

The author is grateful to all the teachers, officers and staffs of IICT for giving their

kind support and information during the study. Thanks are also due to his friends and

colleagues for their encouragement.

The author gratefully acknowledges his parents for their kind co-operation, continued

encouragement and moral supports without which the work could not have been

completed.

Finally, the author is grateful to Almighty Allah.

- IV-
TABLE OF CONTENTS

Page No

I
Certificate
II
Declaration
III
Abstract

!.
IV
Acknowledgement
V
Table of Contents

CHAPTER ONE: Introduction

1.1 General
2
1.2 Objectives
3
1.3 Brief Outline of Methodology

CHAPTER TWO: Database Management System


4
2.1 Introduction
4
2.2 Definition and Concept of Database
4
2.3 Database System versus File System
5
2.4 Information Modelling
) 6
2.4.1 Concept ofInformation Modelling
7
2.4.2 Procedures for Information Modelling
7
2.4.2.1 Steps for Information Modelling
7
2.4.2.2 Rules of Data Normalization
7
2.5 Data Modelling

-v -
'<
2.5.1 Concept of Data Modelling 8
2.5.2 Categories of Data Models 8
2.5.3 Types of Data Modelling 9
2.6 Application of Database Management System 9

CHAPTER THREE: Project Design and Methodology

3.1 Introduction II

3.2 Facts for a Database for a library II

3.3 Database Development 12


3.3.1 Description of the Database Developed 14

3.3.2 Data used for the development IS

3.4 Designing of Data Entry Interfaces 17


3.5 Programming Language 17

CHAPTER FOUR: Software Design


.~
4.1 Definition 18
4.2 A tour to the PC software 18
4.3 Software Testing 28
4.4 Hardware Requirements 28
4.5 Documentation and User's Manual Creation 29

CHAPTER FIVE: Conclusion and Recommendation


)

5.1 Conclusion 30

5.2 Recommendation 30

- VI -
.~ 31
References

Appendix

-VII-
Chapter 1

Introduction

1.1 General

E ducational institution needs library m anagem ent system to track and m anage its

resources. B ooks are checked out, checked in, and requested by library patrons. B ooks

can have special status, if they are placed on reserve or if they are reference books --

these books cannot leave the prem ises. It is rem inded w hen resources are m ore than tw o

w eeks overdue. O ther resources that can be checked out, including softw are, videos,

m usic C D s, each of w hich m ay only be checked out for one w eek at a tim e.

P atrons status 1) influences how long a book can be checked out 2) determ ines w hat

services are available. S tudents can check out a book for four w eeks, and faculty for three

m onths. L ibrary staff m ay keep a book for an entire year. A ny checkable library resource

m ay be renew ed as long as no other patron has requested it. F aculty and library staff can

place a book on reserve for the period of one sem ester, or they m ay bring in foreign

resources (books, papers, disks, m usic C D s, m agazines, or tapes that do not belong to the

library) and put them on reserve.

L ibrary m ust also m anage a large selection of w eekly, m onthly, and quarterly m agazines,

w hich m ay not be checked out but are available as reference m aterials. T hese m agazines

are annually bound into volum es or recorded as m icrofiche. A dditional activities of the

library staff include re-shelving books, renew ing m agazine subscriptions, and ordering

new library resources.


y
L ib ra ry sta ffs a lso p ro v id e a n u m b e r o f o th e r se rv ic e s su p p o rtin g a c tiv itie s in th e re se a rc h

c o m m u n ity a n d fo r th e g e n e ra l p u b lic . D e sig n a te d lib ra ry sta ff a re a lso a v a ila b le to a ssist

p a tro n s w ith th e ir re se a rc h n e e d s u sin g th e c o m p u te r b a se d to o ls a s w e ll a s sta n d a rd h a rd -

c o p y in d e x e s. A fin a l re sp o n sib ility o f th e lib ra ry sta ff is th e a c q u isitio n a n d re tire m e n t o f

b o o k s in th e c o lle c tio n . In a c q u irin g n e w b o o k s, a b a la n c e b e tw e e n m e e tin g th e re q u e sts

o f p a tro n s a n d a c h ie v in g a re p re se n ta tiv e b re a d th in th e c o lle c tio n s is so u g h t. B o o k s a re

re tire d w h e n th e ir c o n te n t is d e e m e d to b e o u t o f d a te a n d o f n o h isto ric a l v a lu e . Id e a lly ,

w h e n a b o o k is o u t o f d a te , it w ill n o t b e re tire d u n til a m o re u p -to -d a te re so u rc e has

re p la c e d it in th e lib ra ry 's c o lle c tio n .

1.2 Objectives

T h e p rim e o b je c tiv e o f th is stu d y is to c o m p u te riz e th e m a n a g e m e n t sy ste m o f a lib ra ry .

T h is is p a rtic u la rly n e e d e d b y e v e ry lib ra ria n to m a n a g e e v e ry re so u rc e a c c u ra te ly . T o d o

so , D B M S su p p o rt is a c h ie v e d b y c re a tin g a d a ta b a se u sin g MS A c c e ss to sto re ,

m a n ip u la te a n d re trie v e th e v a lu a b le d a ta . O n th e o th e r h a n d , to p ro v id e e a sy , fa st a n d

lu c ra tiv e d a ta e n try p ro c e ss, a u se r frie n d ly in te rfa c e is d e v e lo p e d .

T h e o b je c tiv e s o f th is p ro je c t c a n b e su m m a riz e d b e lo w :

I. T o a n a ly se a n d d e sig n a lib ra ry m a n a g e m e n t sy ste m .

2. T o d e v e lo p a sy ste m th a t e lim in a te s m anual m anagem ent th u s re d u c e s th e

p o ssib ility o f e rro r a n d in c re a se se c u rity .

3. To d e v e lo p and p ro v id e a sy ste m th a t IS u p g ra d e a b le to any k in d of

c u sto m iz e d re q u ire m e n ts.

2
.,
1.3 Brief Outline of Methodology

T he m ethodology for developing the softw are w as divided into the follow ing

com ponents, w hich are given below :

1. D ata study and analysis,

2. D ata norm alization and T able D esign,

3. D atabase C reation,

4. Interface D esign,

5. C oding, E rror H andling and D ebugging,

6. T esting and im plem entation.

3
Chapter 2

Database Management System

2.1 Introduction

D a ta b a s e s y s te m s a re d e s ig n e d to m a n a g e la rg e b o d ie s o f in fo rm a tio n . M anagem ent of

d a ta in v o lv e s b o th d e fin in g s tru c tu re s fo r s to ra g e of in fo rm a tio n and p ro v in g

m e c h a n is m s fo r th e m a n ip u la tio n o f in fo rm a tio n . In a d d itio n , th e d a ta b a s e s y s te m m ust

e n su re th e s a fe ty of th e in fo ffila tio n s to re d , d e s p ite s y s te m c ra sh e s or a tte m p ts to

u n a u th o riz e d a c c e s s . If d a ta a re to b e s h a re d a m o n g s e v e ra l u s e rs , th e s y s te m m u s t a v o id

p o s s ib le a n o m a lie s re s u lts .

2.2 Definition and Concept of Database

A d a ta b a s e m anagem ent s y s te m (D B M S ) is a c o lle c tio n o f in te rre la te d d a ta a n d a s e t if

p ro g ra m s to a c c e s s th o s e d a ta . T h e c o lle c tio n o f d a ta , u s u a lly re fe rre d to a s th e d a ta b a s e ,

c o n ta in s in fo rm a tio n re le v a n t to a n e n te rp ris e . T h e p rim a ry g o a l o f a D B M S is to p ro v id e

a w a y to s to re a n d re trie v e d a ta b a s e in fo rm a tio n th a t is b o th c o n v e n ie n t a n d e ffic ie n t.

2.3 Database System versus File System

T h e ty p ic a l file p ro c e s s in g s y s te m is s u p p o rte d b y a c o n v e n tio n a l o p e ra tin g s y s te m . T h e

s y s te m s to re s p e rm a n e n t re c o rd s in v a rio u s file s and it n e e d s d iffe re n t a p p lic a tio n

p ro g ra m s to e x tra c t re c o rd s fro m it a n d add re c o rd s to th e a p p ro p ria te file s . B e fo re

4
database m anagem ent system cam e along, organization usually stored inform ation/data in

such system .

Keeping data/inform ation in file processing system has a num ber of m ajor disadvantages:

y Data redundancy and inconsistency


y Difficulty in accessing data
y Data isolation
y Integrity problem
y Atom icity problem
y Integrity problem
y Concurrent access anom alies
y Security problem s

These difficulties, am ong others, prom pted the developm ent of the database.

2.4 Information Modelling

W henever understanding of a real world phenom enon or interaction is desired the first

step is to build a sim ple m odel representing the phenom enon and perform study and

evaluation of the m odel rather that actual interaction. In building m odel the am biguity

and com plexity in the real world is avoided totally or com pensated with valid

approxim ation. [n fact a system atic study of any phenom enon whether econom ic,

industrial or scientific is done through m odelling. Inform ation m odelling pertains to

developm ent of m odel in inform ation generation, storage, destruction, evaluation,

m anipulation, synthesis and utilizations. These m odels help in system atisation of

inform ation generation, flow, interpretation and synthesis of m ore inform ation.

5
2.4.1 Concept of Information Modelling

The first step of infomlation modelling is to precisely choose only that part of reality,
which is of interest. This is known as Entity. Entity defines other parameters. Entities are

atomic i.e. they are invisible. The parameters if as entity are known as attribute.

Attributes are quantum of information, which describe the entity entirely. Attributes

themselves can be thought of entities, which make the first entity of a composite entity.

The key attribute if one, which distinguishes one occurrence if an entity from other. It is

associated with all other attributes with a I: I (one-to-one) relation.

The second step in information modelling is relationship among entities. It is most


important in making sense if the entity and inter-entity relationship. The relationship is

the information, which links two entities. The relationship can be of four categories:

.:. One-to One (I: I) - One instance of the first entity can correspond to only one

instance of the second entity. It is also known as binary relationship .


•:. One-to-Many (I :N) - One instance of the first entity can correspond to more

that one instance of the second entity .


•:. Many-to-One (N: I) - More that one instance of the first entity van correspond

to the same one instance of the second entity .


•:. Many-to Many (N :N) - More that one instance of the first entity can

correspond to more than one instance of the second entity.

In information modelling, One-to-One (I: I) and One-to-Many (I :N) relationships are

used.

6
2 .4 .2 P ro ced u res fo r In fo rm atio n M o d ellin g

T h e first step fo r in fo n 1 1 atio n m o d ellin g an d ru les o f d ata n o rm alisatio n w ere d escrib e

b elo w :

2 .4 .2 .1 S tep s fo r In fo rm atio n M o d ellin g

S tep 1 : T h e u n iv erse o f d isco u rse (U D O ) o r th e p art if real w o rld sh o u ld b e selected

p ro p erly w ith m in im u m red u n d an cy b u t co m p letely in term s o f en tities.

S tep 2 : E n tities are to b e classified acco rd in g to th eir attrib u te co n ten ts an d m erg ed ,

w h ich h av e o n e-to -o n e (1: 1) relatio n sh ip in to co m p o site en tities.

S tep 3 : T h eir relatio n sh ip am o n g en tities sh o u ld b e d efin ed an d n am ed .

S tep 4 : N o rm alizatio n sh o u ld b e d o n e to red u ce red u n d an cy an d in crease in teg rity .

2 .4 .2 .2 R u les o f D ata N o rm alizatio n

.:. E lim in atin g R ep eatin g G ro u p s: M ak e a sep arate tab le fo r each set o f related

attrib u tes an d g iv e each tab le a p rim ary k ey .

•:. E lim in atin g R ed u n d an t D ata: If attrib u te d ep en d s o n o n ly p art o f a m u lti v alu ed

k ey , rem o v e it to a sep arate tab le .

•:. E lim in ate C o lu m n s n o t d ep en d en t o n K ey : If attrib u tes d o n o t co n trib u te to a

d escrip tio n o f th e k ey , rem o v e th em to a sep arate tab le .

•:. Iso late In d ep en d en t M u ltip le R elatio n sh ip : N o tab le m ay co n tain tw o o r m o re I:N

o r N :M relatio n sh ip s th at are n o t d irectly related .

•:. Iso late S em an tically R elated M u ltip le R elatio n sh ip : T h ere m ay be p ractical

co n strain s o n in fo rm atio n th at ju stifY sep aratin g lo g ically related m an y -to -m an y

relatio n sh ip s.

2 .5 D ata M o d ellin g

F o r an in fo rm atio n sy stem to b e u sefu l, reliab le, ad ap tab le an d eco n o m ic, it m u st b e

b ased o n first o n so u n d d ata m o d ellin g an d o n ly seco n d arily o n p ro cess an aly sis.

7
2 .5 .1 C o n c e p t o f D a ta M o d e llin g

A d a ta m o d e l is a m o d e l d e s c rib in g th e d a ta in a n o rg a n iz a tio n . It p ro v id e s a fra m e w o rk

fo r a b s tra c tin g th e e s s e n tia l q u a litie s o r c h a ra c te ris tic s o f d a ta . D a ta m o d e llin g is th e

p ro c e s s o f a b s tra c tio n a n d d o c u m e n ta tio n u s in g a d a ta m o d e l.

D a ta m o d e llin g c re a te s h ie ra rc h ie s o f a b s tra c tio n a lo n g tw o d im e n s io n s : a g g re s s io n and

g e n e ra liz a tio n . A g g re s s io n id e n tifie s d a ta ite m s a s a rts o f h ig h e r-le v e l, m o re a g g re g a te

d e s c rip to r. G e n e ra liz a tio n c re a te s c a te g o rie s in to w h ic h a d a ta ite m m a y b e c la s s ifie d .

T h e re a re tw o m a jo r c la s s e s o f d a ta m o d e ls - lo g ic a l d a ta m o d e ls o r c o n c e p tu a l d a ta

m o d e ls and p h y s ic a l d a ta m o d e ls . T hese tw o c la s s e s re fle c ts th e fa c t th a t e ffic ie n t

p h y s ic a l s to ra g e a n d re trie v a l o f d a ta m u s t b e d e s ig n e d a ro u n d th e p h y s ic a l c h a ra c te ris tic s

if s to ra g e m e d ia a n d d e v ic e s , b u t u s e rs o f d a ta s h o u ld b e a b le to d e s c rib e , th in k a b o u t a n d

u s e d a ta w ith o u t b e in g c o n c e n tra te d a b o u t its p h y s ic a l s to ra g e .

2 .5 .2 C a te g o rie s o f D a ta M o d e ls

M a n y d a ta m o d e ls h a v e b e e n p ro p o s e d a n d o n e c a n c a te g o riz e th e m a c c o rd in g to th e

ty p e s o f c o n c e p ts th e y u s e to d e s c rib e th e d a ta b a s e s tru c tu re . H ig h -le v e l o r c o n c e p tu a l

d a ta m o d e ls p ro v id e c o n c e p ts th a t a re c lo s e to th e w a y m a n y u s e rs p e rc e iv e d a ta ,

w h e re a s lo w -le v e l o r p h y s ic a l d a ta m o d e ls p ro v id e c o n c e p ts th a t d e s c rib e th e d e ta ils o f

h o w d a ta is s to re d in th e c o m p u te r. C o n c e p ts p ro v id e d b y lo w -le v e l d a ta m o d e ls a re

g e n e ra lly m e a n t fo r c o m p u te r s p e c ia lis ts , n o t fo r ty p ic a l e n d u s e rs . B e tw e e n th e s e tw o

e x tre m e s is a c la s s of re p re s e n ta tio n a l (o r im p le m e n ta tio n ) d a ta m o d e ls , w h ic h

p ro v id e c o n c e p ts th a t m a y b e u n d e rs to o d b y e n d u s e rs b u t th o s e a re n o t to o fa r re m o v e d

fro m th e w a y d a ta is o rg a n iz e d w ith in th e c o m p u te r. R e p re s e n ta tio n a l d a ta m o d e ls h id e

s o m e d e ta ils o f d a ta s to ra g e b u t c a n b e im p le m e n te d o n a c o m p u te r s y s te m in a d ire c t

w ay.

)
C onceptual data m odels use concepts such as entities, attributes, and relationships. As

entity represents a real-w orld object or concept that is described in the database. An

attribute represents som e property of interest that further describes an entity. A

relationship am ong tw o or m ore entities represents an interaction am ong the entities. T he

E ntity-R elationship m odel is the popular high-level conceptual data m odel.

2.5.3 Types of Data Modelling

T he data m odelling consists of three interrelated pieces of inform ation, the data object,

the attributes that describe the data object and the relationship that connect data objects to

one another. A data object is a representation of alm ost any com posite inform ation that

m ust be understood by softw are. C om posite inform ation m eans som ething that has a

num ber of different properties or attributes.

Six different types of data m odels are given below :

I. E ntity-R elationship M odel (E -R M odel)

2. R elational M odel

3. O bject-O riented D ata M odel

4. O bject-R elational D ata M odel

5. H ierarchical D ata M odel

6. N etw ork D ata M odel

2.6 Application of Database Management System

D atabase m anagem ent system IS w idely used 1tl the real w orld. H ere are som e

representative applications:

9
,
• Banking: For custom er inform ation, accounts, loans and banking transaction.

• Airlines: For reservation and schedules inform ation. Airlines were am ong the first

to use database in a geographically distributed m anner-term inals situated around

the world accessed the central database system through phone lines and other data

network.

• Universities: For student inform ation, course registration and grades.

• Credit card transactions: For purchases on credit cards and generation of m onthly

statem ents.

• Telecom m unications: For keeping records of calls m ade, generating m onthly

bills, m aintaining balances on prepaid calling networks.

• Finance: For storing inform ation about holdings, sales and purchases of financial

instrum ent such as stocks and bonds.

• Sales: For custom er, product and purchase inform ation.

• M anufacturing: For m anagem ent of supply chain and for tracking production of

item s in factories, inventories of item s in warehouse/stores and orders for item s.


• Libraries: For m anagem ent of library resources.

• Hum an resources: For inform ation about em ployees, salaries, payroll taxes and

benefits and for generation of paycheques.

10
Chapter 3

Project Design & Methodology

3.1 Introduction

The goal of this project was to develop a software, which will make the library
management system easy, reliable and less laborious and quick. To achieve the goal,
following works are set to the target:

.:. To make the management system easy and updateable .


•:. To make the management system reliable and efficient.
.:. To generate various type of report, which is urgently required in decision-
making process.

To achieve the above target, the data were analysed first. Collection of information

for a particular job is essential to develop the whole project. Various important

information about the project was collected like collection of data for daily

transaction books. Infonnation is analysed in proper way and store in proper

format in the database.

:> 3.2 Facts for a Database for a library

The facts define the functional requirements that the Database must meet.
They form the basis for agreement between the User and the Database Designer and are
written In a form of structured English that is clear and unambiguous.

II
A . T he A rea being M odelled is :-

A L ibrary.

B . T he T hings ofInterest, ('T H IN G S'), include :-

B . I A uthors

B .2 B ooks

B .3 B ook C ategories

B .4 B ooks O ut on L oan

B .S U sers

B .6 U ser B orrow ings

C . T hese T H IN G S O F IN T E R E ST are R elated as follow s :-

C . I A n A U T H O R can w rite m any B O O K S.

C .2 A B O O K can have m any A U T H O R S.

C .3 A B O O K can be in m any C A T E G O R IE S.

C .4 A U SE R can be associated w ith zero or m any B O O K S_O U T _O N _L O A N .

C .S A B O O K _O U T _O N _L O A N m ust alw ays be associated w ith one and only one

U SE R .

D . T ypical E nquiries include :-

D .I I-low m any B O O K S are overdue?

D .2 D o w e have any B O O K S by Schildt?

3.3 Database Development

R elational database m anagem ent system w as used to m ange the database. T he

database w as developed in M S A ccess in five tables w ith three relationships. T he

total data have been norm alized and then tables are obtained.

12
Figure 3.2.1: A physical data model for a library

US@lS

user id
use,_n ••me
user_address:
phonll_numb.,
email_address
other_user_details

Figure 3.2.2: A conceptual data model for a library.

13
3.3.1 Description of the Database Developed

F o r s im p lic ity , fiv e ta b le s h a v e b e e n d e s ig n e d n a m e ly M e m b e r ta b le , B o o k ta b le , F in e

ta b le , T ra n s a c tio n ta b le a n d R e tu rn ta b le . B rie f d e s c rip tio n o f th e ta b le s a re g iv e n b e lo w :

~ M em ber T a b le - it h a s S IX c o lu m n s (M e m b e r - lD , M em - N am e, P ro fe s s io n ,

M e m _ A d d re s s , M e m _ C o n t_ N u m b e r, M e m _ D a te ) h o ld in g v a lu e s fo r M e m b e r ID ,

M e m b e r n a m e , P ro fe s s io n o f th e m e m b e r, M e m b e r A d d re s s , M e m b e r c o n ta c tin g

n u m b e r, M e m b e r e n try d a te .

\. M em ber ID - N um ber

M em N am e - T ext

P ro fe s s io n - T ext

M em A d d re s s - M em o

M em C o n t N u m b e r-T e x t

M em D a te - D a te /T im e

~ B o o k T a b le - it h a s s e v e n c o lu m n s (B o o k _ ID , B o o k _ N a m e , B ook_T ype, A u th o r,

P u b lic a tio n , C o p ie s , D a te _ E n try ) h o ld in g v a lu e s fo r B o o k ID , B o o k N a m e , B o o k

T y p e , B o o k 's A u th o r, P u b lic a tio n o f th e b o o k , C o p ie s o f b o o k , B o o k e n try d a te .

B ook ID -N u m b e r

B ook N am e - T ext

B o o k _ T y p e -T e x t

A u th o r -T e x t

P u b lic a tio n - T ext

C o p ie s - N um ber

D a te _ E n try - D a te /T im e

~ F in e T a b le - it has S IX c o lu m n s (F in e _ ID , M e m _ ID , T ra n s _ ID , R e t_ ID ,

F in e A m o u n t, D a te F in e ).

F in e ID - A u to N u m b e r

14


F in e A m o u n t -N u m b e r

~ T ra n s a c tio n T a b le - it has fo u r c o lu m n s (T ra n s_ ID , M e m _ lD , B o o k _ ID ,

D a te Issu e )

~ R e tu rn T a b le - it h a s th re e c o lu m n s (R e U D , T ra n s _ ID , D a te _ R e tu rn )

Relationship

MeftJer_ID
M e r n }• • •" ,
Profession
M em _M ae"
M e r n j:C < U u m e r
Mem_Date DO Mem_ID
1
00 TranJD
R e lJ D
F i:1 e A m o u n t
D a le ] in e

!kd....1l

-
B ook_N am e
B o o k _ T lP "
1

Pubf<am
C q lie s
D a le _ E r tr y

F ig u re 3 .3 .1 : R e la tio n s h ip o f T a b le s

3.3.2 Data Used for the Development

T h e s e s e ts o f e x a m p le d a ta fo r th e fiv e ta b le s a re s h o w n b e lo w :

15
M e m b e r ta b le :

M em ber 10 M em _ N a m e P ro fessio n M em _ A d d ress M em _ C o n t_ N u m b er M em _ D a tc

I M oam m ad R a g ib A h sa n S erv ice 14/A G a rd en R o a d 9115604 2 2 -M a r-0 3

2 Sibu S tu d en t E sk a to n R oad 1234567 2 2 -M a r-0 3

3 M d . R eza u illa sa n S tu d en t S h a m o li. D haka 8129369 2 5 -M a r-0 3

B o o k ta b le :

B ook_1D B ook_N am e B ookJype Author Publication Copies D a te_ E n try

I MeSO V isu a l B a sic P ro g ra m m in g L y le B r y a n t T ech m cd ia 2 2 0 -M y -0 2

2 D a ta b a se M a n a g em en t D a ta b a se R aghu M cG ra w - I 2 2 -M a r-0 3

S y stem R a m a k rish n a n Hill

F in e ta b le :

F in e_ ID M em _1D T ra n s_ ID R eU D F in eA m o u n t D a te_ F in e

2 I 14 3 6 2 6 -M a r-0 3

3 I 14 3 3 2 6 -M a r-0 3

4 2 15 4 8 2 6 -M a r-0 3

T r a n s a c tio n ta b le :

T ra n s_ ID M cm _1D B o o k _ ID D a te_ Issu e

2 2 2 2 2 -M a r-0 3

3 2 2 2 2 -M a r-0 3

4 I I 2 2 -M a r-0 3

5 2 1 2 2 -M a r-0 3

6 2 2 2 6 -M a r-0 3

7 I 2 2 2 -M a r-0 3

8 3 2 2 2 -M a r-0 3

9 2 I 1 5 -M a r-0 3

10 I I 2 2 -M a r-0 3

11 2 1 2 2 -M a r-0 3

12 I I 2 8 -M a r-0 3

16
.J.
R e tu rn ta b le :
Rctum_ID Tran_ID Date_Return
I 12 2 6 -M a r-0 3

2 13 2 9 -M a r-0 3

3 14 2 6 -M a r-0 3

4 15 2 6 -M a r-0 3

5 16 2 9 -M a r-0 3

6 17 3 1 -M a r-0 3

3.4 Designing of Data Entry Interfaces

T h e m a jo r c o n fig u ra tio n o f In fo rm a tio n M anagem ent S y ste m depends o n d a ta

e n try , b e c a u se d iffe re n t k in d o f m a n a g e ria l d e c isio n n e e d s in fo rm a tio n fro m th is

so ftw a re . The so ftw a re d e v e lo p e d fo r Graphical User Interface (GUI) w ith

d a ta b a se c o n n e c tiv ity re q u ire s tw o b a sic c o m p o n e n ts - Back-End and Front-End.


M S A c c e ss is u se d a s B a c k -E n d in th is so ftw a re .

3.5 Programming Language

A fte r d e sig n in g th e d a ta b a se , n o w it w a s th e tim e to c h o o se th e p ro g ra m m in g

la n g u a g e fo r th e lib ra ry m anagem ent sy ste m . The p ro g ra m m in g la n g u a g e of

V isu a l B a sic 6 w a s u se d fo r th is p ro je c t. In fu tu re th e p la tfo rm in d e p e n d e n t

la n g u a g e Ja v a c a n b e u se d . T h e Crystal Report w a s u se d to re trie v e d a ta d ire c tly

in th e p ro je c t.

17
y

Chapter 4

Software Design

4.1 Definition

S o ftw a re d e s ig n is a n ite ra tiv e p ro c e ss th ro u g h w h ic h re q u ire m e n ts a re tra n s la te d in to a

" b lu e p rin t" fo r c o n s tru c tin g s o ftw a re . In itia lly , th e b lu e p rin t d e p ic ts a h o lis tic v ie w of

s o ftw a re . T hat is , th e d e s ig n is re p re s e n te d at a h ig h le v e l o f a b s tra c tio n - a le v e l th a t

can be d ire c tly tra c e d to th e s p e c ific s y s te m o b je c tiv e and m o re d e ta ile d d a ta , fu n c tio n a l,

and b e h a v io u ra l re q u ire m e n ts .

4.2 A tour to the PC software

Institute of Information &


Communication Technology (IICT)

F ig u re 4 .1 : Home page

18
O " velO p lllen t ofth e tlb rd ry " 1,m agem en t S Y lO tem [M em b en h lp F orm ) _ ." " '- ~ '! i i i ? i i

M e m b e r D e ta il I n f o r m a tio n
M•••. IO: 11

0_ fSls;;:~;i;.;:=======:::J
A d d - e n : 1 4 1 A G ~ A O G d .W e s tk 8 W 5 1 ~ .
D haka 125

______ r:J

,..
M_
C ortedN ..-nber{tt

D.
19'11$G 4'-

1 3 I2 2 J2 O O 3 -' _I
--'

F ig u re 4 .2 : L o c a tio n p a g e re v e a ls M e m b e r in fo rm a tio n

.J 19
D e v e lo p m e n t o r th e L IL r a r y " 1 < ln a l;J e m e n t S Y ite m - (H o o k D e ta il In fo r m a tio n fo rm ) _

B o o k D e ta il I n f o r m a tio n

."'d " "


800kNalllll: j"'."C S"D '"V 1;;.",;;;iii.:;;"",,;;:. ----------------------"

B o o k T w e : I P r D lJ a T lI I 'W I g ,~ .!1

A I .6 o r ll~ I L , . Bryn

"""""'"
Noof Cqlin:
I!T.T"'." •••••
12
;;;:::=========:;;;;:=====:J
CqliB

F ig u r e 4 .3 : L o c a tio n p a g e r e v e a ls B o o k in f o r m a tio n

• .1
20
.•. _- B o o k Issu e

B o a k IO : ]1 --=.J

!JII!!ll'" ------------1lIIIIII
rSo::le<:tion
Twe---------,
B o o k D e ta il In fo rm a tio n

"""""O M rl------a::l.
r ~B ookTp

r ••••••••

Boolo.lD: f.l ==::;


---========-==-::::--:------
BookN_ rl

-,
~I'li
B " 'T _ ~ ~ ~

""'- rl-- "-

OK I '""" I

F ig u re 4 .4 : A fte r s e le c tin g b o th th e M e m b e r ID a n d B o o k ID ( I s t fig .), it s h o w s


nd
th e d e ta il in fo rm a tio n o f th e s e le c te d b o o k (2 fig ).

21
Dt:vduplilent Ilf 'he l,brdry "1dndgement System - (Return Book] ~
••• _ H o I>

R e tu r n B o o k
Enlerl_lD: , I
----

"-I

. .l a u e O e t * - - - - - - - - - - - - - - - - - - - ~

I D"""_I o. of RiIIUn: I II

I ToWr:ne: rl•• -:.-:.-:.-:..-~-~-~- •••- .• Tl


I

F ig u re 4 .5 : L o c a tio n p a g e re v e a ls th e in fo rm a tio n o fre tu m in g b o o k s h o w in g to ta l

fm e , ifa n y .
>

22
Dl':\lelopml:"nt of the lIbrary Manageml':nt System Report ~-_ ~_ ~ ~-_ -_ ====...:....... .,.....,.,.....~
) X
•••••••
SH'
1
I''''''' 3 n I~ ~ I , d'
~~I'1J"

• Bangladesh University o f E n g in e e r in g & Technology


I n s titu te o f I n f o n n a tlo n & C o m m u n ic a tio n T e c h n o lo g y

- -.
D e ta ils M e m b e r I n f o n n a tlo n

ID I.lli!!! Pho. !!!!o


I M o o m m o I R o g i> • • • • • • s .rn .. 14fA OudeJl.Roed. West 9115604 2 2 -M u -0 3
(lliI< m » ••••••• b o n < D•••• 1 2 5
2 sm . S_ •••••• R o o !, DbW 88118888 22-MIU~
3 Md. R.e%anl Hasan S t U '" -'~D"" 8129369 28-MIl-03

F ig u r e 4 .6 : R e p o r t s h o w in g d e ta il M e m b e r in f o r m a tio n

23
-.,

D ev elo p m en t o f th e lib ra ry M<lIndQement S y stem R ep o rt --- - ~-=-~ _~ ~-=__~


~ ~I • IJ"

• B an g lad esh U n iv ersity o f E n g in eerin g & T ech n o lo g y

In stitu te o fW o n n atio n & C o m rn n n lcatio n T ech n o lo g y

D etails M tm b er In fo n n atlo n

M_erm: 3
M._llr Na.!: M d. R etaul H asan

Pn •••• a: S""''''
A u....: SM m oti, D hob

P".: 5129369

_ofH"'~: 28-M az-2003

F ig u re 4 .7 : R ep o rt sh o w in g in d iv id u al M em b er in fo rm atio n
>

24
J x ~ 9 1!lXl% :::J IJ I~ ~ 1_•......
' '" I ~ ~I • II"
" •.•••• 1

.B an g lad eS h U n iv ersity o f E n g in eerin g & T ech n o lo g y

Instltutt ofInfonnation & C om m unication T tchnology

D ttails B ook Infonnation

IIookW :

B ook _: M C SD V iruolB .,;,

B ookT ".: ~

A_~r.Lylo fuym I
P'1IIII•••• : Teclun!dil.

N oo f C o o "': 2

_ ofEmy: :!l-M q-2lIJ2

F igure 4.8: R eport show ing each B ook inform ation

25
O e ve lo p n te n t o f th e L .b rd ryM d lld q e n te n t S yste m R e p o rt ----------==-__ -~ --=---=-=-~_-=- -.:;,& i& x
Ix ~ ~ ltlX l% 31J I~ ~ I t of 1

P t_1

B an g lad esh U n iv ersity o f E n g in eerin g & T ech n o lo g y


In .titu tt o f in fo rm atio n & C o m rn n n lcatio n T tch n o lo g y

D ally Ism td B o o k in fo rm atio n

D ate: W ed n esd ay , 2 6 M arch , 2 0 0 3

1Ioo.IIl IIttlL II! McWlqID


9 1 M C S D V ;",JB oo;, 2
10 1 M C S D V hIlB R : 1
11 I M C S D V irroIl1B lllD c 1
12 1 M C S D V inIIlIB en: 2
13 I M C S D V im IJ.B M ic 1
16 1 M C S D V ;",J a..;, 2

F ig u re 4 .9 : R ep o rt sh o w in g d aily issu ed B o o k (s)

26
Development o f th e llb ta ry M anagem ent S y s te m Report ~ _ -- _- =-==-=-- .- ~M- -

,.•.
J X
PI ••••• I
::J
S 9I' ••..•. IJ I~ ~ 1 1 'e ll
~ ~ olJ"
'

• Bangladesh University of Engineering & Technology


In stitu te o f In fo rm a tio n

D a lly Issn e d B ook


& C O D llD o o ie a tio n T e e lm o lo g y

In fo n o a tio n

D a l.F rid a y , 1 1 A p ril, 2 0 0 3

la_Date

•. ,
28-Mar-03

• .. ~

F ig u re 4 .1 0 : R e p o rt sh o w in g d a ily re tu rn e d B o o k (s)

27
"

4.3 Software Testing

Software testing is a critical elem ent of software quality assurance and represents the

ultim ate review of specification, design, and code generation.

Tests have been planned before testing begins. During developing the application, the

traces have been kept where and under what conditions will be perform ed. All the tests

are traceable to the librarian requirem ents. The software Seagate Crystal Report has been

used with this software to show the reports.

4.4 Hardware Requirements

M inim um configurations of the hardware required for the developed software are

described below:

Requirements Details
Processor 1. Recom m ended Processor: Pentium III or above

2. M inim um Processor: Pentium I

Com patible operating system s W indows 95, 98, NT, 2000, XP

RAM 1. Typical: 256 M B (512 M B recom m ended)

2. M inim al installation: 128 M B (256 M B

recom m ended)

Hard disk 1. Typical installation: 20 GB

2. M inim al installation: 13 GB

3. Custom installation: depends on com ponents

selected for installation

Others LAN Card

28
..•
4.5 Documentation and User's Manual Creation

Documentation is the process of making the whole work in a document (like a file
in a Microsoft Word). It helps the future system analyst or programmer to change
or update the system.

.•.
'

29
Chapter 5

Conclusion and Recommendation

5.1 Conclusion

D e s ig n o f a p ro g ra m depends u p o n th e s ty le c h o s e n b y th e p ro g ra m m e r. N one can say

th a t h is o n e is th e la s t a s b e tte r a n d b e tte r s o lu tio n s a re c o m in g e v e ry d a y . T h e a u th o r h a s

m a n y lim ita tio n s in h is s o ftw a re , s o m e m a y d u e to ig n o ra n c e a n d s o m e m a y d u e to la c k

of e x p e rie n c e . T h e re a re m any chances fo r o th e rs to enhance th is s o ftw a re . It is

a p p re c ia te d fo r th e fo llo w e rs to g iv e s o m e th in g b e tte r.

5.2 Recommendations

I) Java p ro g ra m m in g la n g u a g e can be used in s te a d o f V is u a l B a s ic p ro g ra m m in g

d u e to its p la tfo rm in d e p e n d e n c y .

2) In th is s o ftw a re th e re is n o p ro v is io n o n p a ssw o rd s y s te m . It c a n b e a d o p te d in th e

s y s te m .

30
J
R e fe r e n c e s

1. F reeze, S. W ayne (2 0 0 0 ). "V isual Basic 6 D atabase Program m ing Bible",

ID G Books W orldW ide, Inc., Foster City, California, U SA .

2. M c M a n u s, P . J e ffe r y (1 9 9 9 ). "D atabase A ccess w ith V isual Basic 6", G .C.

J a in for Techm edia, A nsari Road, N ew D elhi-I 10002, India

3. P e tr o u tso s, E . (2 0 0 1 ). "M astering V isual Basic 6", BPB Publications, B-14,

Connaught, N ew D elhi-I 1000 I, India

4. P r e ssm a n , S. R ogers (2 0 0 1 ). "Softw are Engineering: A Practitioner's

A pproach", M cG raw -H ill Com panies, Inc. 1221 A venue, N ew Y ork.

5. S im p so n , A la n a n d R o b in so n , C e le ste (1 9 9 9 ). "M astering A ccess 2000",

BPB Publications, B-14, Connaught, N ew D elhi-I 10001, India.

31
A p p en d ix

T h e V isu al B asic sou rce cod es are given b elow :

frm A b ou t.frm

O ption E xplicit

P riv a te S u b C o m m a n d l_ C lic k O
U n lo a d Me
End Sub

frm B ook .frm


O p tio n E x p lic it
D im W ith E v e n ts rs M e m A s A D O D B .R e c o rd s e t

P riv a te S u b c m d C lo s e _ C lic k O
U n lo a d Me
End Sub

P riv a te Sub cm dD eL C lic k O


rsM em .D elete
rsM em .M oveL ast
End Sub

P riv a te S u b c m d N e w _ C lic k O
, On Error OoTo eIT _cm dN ew _C lick
If c m d N e w .C a p tio n ~ " A d d N e w M e m b e r" T hen
rs M e m .A d d N e w
cm dN ew .C aption = "Save"
E ls e
rsM em .U pdatc
rsM em .M oveL ast
cm dN ew .C aption = "A dd N ew M em ber"
E n d If

End Sub

P riv a te S u b c m d N e x t_ C lic k O
If N o t rs M e m .E O F T hen
rsM cm .M oveN ext
E ls e

M sgB ox " Y o u a re in L a s t R e c o rd " , v b O K O n ly , m o d C o n tro L m s g T itle


E n d If
End Sub

P riv a te S u b c m d P re v _ C lic k O

If N o ! rs M e m .B O F T hen
rsM em .M oveP revious
E ls e

, -i-
)
'f M sg B o x " Y o u a re in F irst R eco rd " , v b O K O n ly , m o d C o n tro l.m sg T itlc
End If

End Sub

Private Sub emdUpdate _ CliekO


rsM cm .U p d ate
End Sub

P riv a te S u b field s_ L o stF o cu s(ln d ex A s In teg er)


If Index ~ 6 Then
fields(lndex).Text ~ CStr(Val(lields(lndex)))
End If
End Sub

Private Sub Form _ LoadO


Set rsMem ~ New ADODB.Reeordset
rsMem.Open "select. from tblBookDetails Order by Book _ID", DBCon.condb, adOpenStatie,
ad L ock O p tim istic

D im o T ex t A s T ex tB o x
'B in d th e text b oxes to th e d ata p rovid er
F or E ach oT ext In M e.field s
S et o T ex t.D a ta S o u rce = rsM em
N ext
End Sub

frm C a len d er.frm

Option Explicit

Private Sub emdCaneel_ClickO


Unload Me
End Sub

Private Sub emdOK CliekO

Dim strSQL As String, IblCaption As String

Dim rslD As ADODll.Reeordset


Set rslD = New ADODB.Reeordset

IfmodControl.CurrReport ~ "DlB" Then


strS Q L = " select * from tb lT ran saction W h ere D atcJssu c = # " & C alcn d arl.V alu e & U#"
EIsclfmodControl.CurrReport ~ "DRB" Then
strS Q L = " select * from tb lR ctu rn W h ere D ate_R etu rn = # " & C alen d arl.Y alu c & u#"
End If

rslD.Open strSQL, DBCon.condb, adOpenStatie, adLockOptimistie

If rslD.ReeordCount > 0 Then


m o d C o n tro l.R e p P a ra D a te = C a le n d a rl.V a lu e
limReport.Show I
Unload Me
Else
M sgBox " S o rry !!! Y o u s e le c t w ro n g d a te " , v b O K O n ly , m o d C o n tro l.m s g T itle
End If

- II -
'I End Sub

P riv ate S u b F o rm _ L o ad ()
C alen d arl.D ay ~ D ay (D ate)
C alen d arl.M o n th ~ M o n th (D ate)
C alendarl.Y ear = Y ear(D atc)
End Sub

frm F indB ook.frm


O ption E xplicit
D im W ithE vents rsM em A s A D O D B .R ecordset
D im fN am e A s String

P riv ate S u b cm b B o o k T y p e_ C lick ()


Set rsM em =: N ew A D O D B .R ccordset

rsM em .O p en "select' fro m tb IB o o k D etails B o o k _ ID W h ere" & IN am e &" ~ '" &


T rim (cm b B o o k T y p e) & ""', D B C o n .co n d b , ad O p en S tatic, ad L o ck O p tim istie

D im oT ext A s T extB ox
'B ind the text boxes to the data provider
F o r E aeh o T ex tln M e.field s
Set oT ext.D ataSourcc = rsM em
N ext
End Sub

P riv ate S u b em d C lo se _ C liek ()


U n lo ad Me
End Sub

P riv ate S u b em d N ex t_ C liek ()


If N o t rsM em .E O F T h en
rsM cm .M oveN ext
E lse
M sg B o x "Y o u a re in L a s t R e c o rd ", v b O K O n iy , m o d C o n tr o l.m s g T itle

E n d If
End Sub

P riv ate S u b em d O K _ C liek ()


Issu eB o o k .tx tM em (1 ).T ex t ~ rsM em .field s("B o o k _ ID ")
U n lo ad M e
End Sub

P riv ate S u b cm d P rev _ C liek ()

If N o t rsM em .B O F T h en
rsM em .M ovePrevious
E lse
M sg B o x "V o u a re in F ir s t R e c o r d " , v b O K O n ly , m o d C o n tr o l.m s g T itle
End If

End Sub

P riv ate S u b em d U p d ate_ C liek ()


rsM cm .U pdate
End Sub

P riv ate S u b field s_ L o stF o eu s(ln d ex A s In teg er)


Ifln d ex ~ 6 T h en

- III -
fields(lndex).Text ~ CStr(Val(fields(lndex)))
End If
End Sub

Private Sub optSelType_Click(lndex As Integer)


D im rsY al A s A D O D B .R ecordset
Dim SelLabel As String

cmbBookType.Clear

If optSeIType(lndex).Value ~ True Then


Select C ase Index

Case 0
fN am e = "B ook_T ype"
SeiLabeI ~ "Book Type"
C ase I
fN am e = "A uthor"
SelLa bel = "A uthor N am e"
C ase 2
fN am e = "Publication"
SelL abel = "Publication N am e"
Case 3
fN am e = "B ook_N am e"
SelL abel = "B ook N am e"

End Select
End If

Label I I.Caption ~ "Select" & SelLabel

Set rsVal ~ New ADODB.Recordset

rsVaLOpen "selecl " & tName & " from tbIBookDetails Order by " & IName, DBCon.condb,
adO penStatic, adL ockO ptim istic

While Not rsVaLEOF


cmbBookType.AddItem rsVaLfields(O)
rsY al.M oveN ext
Wend
End Sub

frm ID R eport.frm

O ption E xplicit

Private Sub cmdCancel_ClickO


rnodControl.CurrReport = "Noting"
Unload Me
End Sub

Private Sub cmdOK _ ClickO


modControLRepParaID ~ Val(Combol.Texl)
frmReport.Show I
Unload Me
End Sub

Private Sub Form_LoadO


Dim strSQL As String. IblCaption As String

- iv-
\
D im r s lD A s A D O D B .R e c o r d s e t

S e t r s lD = N e w A D O D B .R e c o r d s e t

I f m o d C o n t r o l.C u r r R e p o r t = " IM I" T h en


IblC aption ~ "S elect M em ber /D "
s t r S Q L = " s e le c t M e m b e r _ I D f r o m t b lM e m b c r D e t a ils ord er b y M em b er_ID "
E lselfm odC ontrol.C urrR cport ~ "IB !" T hen
IblC aption ~ "S elect B ook ID "
strS Q L ~ "select B ook_/D from tblB ookD etails order by B ook_/D "
E nd If

rs/D .O pen strS Q L . D B C on.condb, adO penS tatic, adL ockO ptim istic

W hile N ot rsID .E O F

C om boJ.A ddltem rsID .lields(O )

r s lD .M o v e N e x t
W end
C om boJ.L istIndex ~ 0
L abel I.C aption ~ IblC aption
E nd S ub

f r m M a in .f r m

O p t io n E x p lic it

P rivate S ub M D iF orm _ L oadO

E nd S ub

P rivate S ub m nuA bout_ C lickO


frrnA bout.S how I
E nd S ub

P rivate S ub m nuB ook _ C lickO


frrnB ook.S how
E nd S ub

P rivate S ub m nuB ookA II_C lickO


m o d C o n t r o I .C u r r R e p o r t = " D B L "
frm R eport.S how J
E nd S ub

P rivate S ub m nuB ookln_C lickO


m o d C o n t r o l.C u r r R e p o r t = "181"
frrnlD R eport.S how I
E nd S ub

P rivate S ub m nuD aiIylssuc_C lickO


m odC ontrol.C urrR eport = "D lB "
frrnC alender.S how I
E nd S ub

P rivate S ub m nuD ailyR et_C lickO


m odC onlrol.C urrR eport ~ "O R B "
frrnC alender.S how I
E nd S ub

. v.
Private Sub mnuExit_CliekO
DBCon.CloseConnection
End Sub

Private Sub mnuLMSHelp _ CliekO


M sgBox "Help will be available at the time of future implementation", vbOKOnly,
modControl.msgTitle
End Sub

Private Sub mnuMemAll_CliekO


modControl.CurrReport = "DML"
fmnReport.Show I
End Sub

Private Sub mnuMember _ ClickO


fnnM ember.Show
End Sub

Private Sub rnnuM emln _ ClickO


modControl.CurrReport ~ "IMI"
fmnIDReport'show J
End Sub

Private Sub mnuRet_ ClickO


RetumBook.Show
End Sub

Private Sub mnuTran_ Click()


IssueBook.Show
End Sub

frm M em ber.frm
Option Explicit
Dim WithE vents rsM em As ADODB.Recordset

Private Sub cmdClose _ ClickO


Unload Me
End Sub

Private Sub cmdDel_CliekO


rsM em.Delete
rsM em.M ovcLast
End Sub

Private Sub cmdNew _ ClickO


IfcmdNew.Caption = "Add New M ember" Then
rsMem.AddNew
cmdNew.Caption = "Save"
Else
rsMem.Update
rsM cm.M oveLast
cmdNew.Caption ~ "Add New Member"
End If
End Sub

Private Sub cmdNext_ClickO


If Not rsMem.EOF Then

- VI -
)
rsM em .M oveN cxt
E ls e
M sgBox "Y ou are in Last R ecord", vbO K O nly, m odC ontrol.m sgTitlc
E n d lf
End Sub

P riv a te S u b e m d P re v _ C lie k O

If N o t rs M e m .B O F T hen
rsM em .M ovePrevious
E ls e
M sgBox "Y ou are in First R ecord", vbO K O nly, m odC ontrol.m sgTitlc
E n d If

End Sub

P riv a te Sub C om m and 1 _ C lie k O

End Sub

P riv a te S u b c m d U p d a te _ C lic k O
rsM em .U pdate
End Sub

P riv a te S u b F o rm _ L o a d O
Set rsM em = N ew A D O D B.R ecordset
rsM em .O pen "select * from tblM em berD etails O rder by M em ber_JD ", D BC on.condb, adO pcnStatic,
adLockO ptim istic

D im oText A s TextBox
'Bind the text boxes to the data provider
For E aeh oT ext In M e .tie ld s
Set oText.D ataSource = rsM cm
N ext
'# # -'1 '1 '1 -# # ' M c d iu m d a te (U S ). E x a m p le : 2 0 -M a y -9 2
End Sub

frm O pen.frm
O ption Explicit

P riv a te S u b F o rm L oadO

End Sub

frm R eport.frm
O p tio n E x p lic it
D im c rx R e p o rt A s C R A X D R T .R e p o rt
D im c rx S u b R e p o rt A s C R A X D R T .R e p o rt

D im c rx A p p lic a tio n A s N e w C R A X D R T .A p p lie a tio n


D im c rx D a ta b a s e T a b le A s C R A X D R T .D a ta b a s e T a b le
'D im W ithEvents Section5 A s craxdrt.Section
'D im W ithEvents Section3 A s craxdrt.Scction

P riv a te S u b S e tS u b R e p o rtL o a c tio n O


'O n Error G oTo err_SetSubR eportLoaction

- vii .
.1
D im i A s In te g e r

F o r E a c h c rx D a ta b a s e T a b le In c rx R e p o rt.D a ta b a s e .T a b le s
c rx D a ta b a s e T a b le .L o c a tio n = A p p .P a th & " \m d b s \L ib ra ry M a n a g c m e n tS y s .m d b "
N e x t c rx D a ta b a s e T a b le

'e x t_ S e tS u b R e p o rtL o a c tio n :


. E x it S u b

'e rr _ S e tS u b R e p o rtL o a c tio n :


, P ro c c s s O B E rro r
, R e s u m e e x t_ S e tS u b R c p o rtL o a c tio n

End Sub

P riv a te S u b C R Y ie w e rl_ C lo s e B u tto n C lic k e d (U s c O c fa u lt A s B o o le a n )

End Sub

P riv a te S u b F o n n _ L o a d O
D im c u rR A s S trin g , R c p In d e x A s In te g e r
c u rR = m o d C o n tro l.C u rrR e p o rt

If c u rR ~ "D IB " T h e n
R e p ln d c x ~ 1
E ise lf c u rR ~ "D R B " T h e n
R e p ln d e x ~ 2
E lse lf c u rR = "D M L " T h e n
R e p ln d e x ~ 3
E lse lf c u rR ~ "IM I" T h e n
R e p ln d e x ~ 4
E lse lf c u rR ~ "D B L " T h e n
R e p ln d e x ~ 5
E ise lf c u rR ~ "1 8 1 " T h e n
R e p ln d c x ~ 6
E n d If

S e t c rx R e p o rt ~ c rx A p p lic a tio n .O p c n R e p o rt(A p p .P a th + "\R e p o rts\" &


m o d C o n tro l.R c p N a m e (R c p ln d e x ) )

c rx R e p o rtD a ta b a se . T a b le s( I ).S c tL o g O n ln fo A p p .P a th + "\m d b s\L ib ra ry M a n a g e m e n tS y s.m d b "

S c tS u b R e p o rtL o a c tio n

If c u rR = " IM I" O r c u rR = " IB I" T h e n


c rx R e p o rt. P a m m c tc rF ie ld s .1 te m ( I ).C le a rC u rrc n t Y a l u e A n d R a n g e
c rx R c p o rt. P a m m c tc rF ie ld s .llc m ( 1 ).A d d C u rre n t Y a lu e m o d C o n tro l.R e p P a ra l D
E n d If

If c u rR = "018" O r c u rR = "O R B " Then


c rx R e p o rt.P a ra m c te rF ie ld s .lte m ( 1).C le a rC u rre n t Y a l u e A n d R a n g e
c rx R e p o rt.P a ra m e te rF ie ld s . I te m ( I ).A d d C u rre n t Y a lu e m o d C o n tro l.R e p P a ra O a te
E n d If

C R V ic w e r 1 .R e p o rtS o u rc e = c rx R e p o rt
'c a ll fo rm re s iz e to v ie w re p o rt
F o rm _ R e s iz e

- V111 -
\
C R V iew er I. V icw R cp o rt
S crcen .M o u scP o in ter = 0
End Sub

P riv a te S u b F o n n _ R csizeO
C R V ie w e rl.T o p ~ 0
C R V ie w e rl.L e l\ ~ 0
C R V icw er I.H eig h t = S ca leH cig h t
C R V ie w e rl.W id th ~ S c a lc W id th
End Sub

Issu eB o o k .frm

O p tio n E x p licit
D im W ith E v cn ts rslssu e I\s A D O D B .R cco rd set
D im A d d N cw T ra n A s B o o lea n

P riv a te S u b c m d B o o k F in d _ C lic k O
frm F in d B o o k .S h o w I
End Sub

P riv a te S u b c m d C lo s c _ C lic k O
U n lo a d Me
End Sub

P riv a te S u b c m d O K _ C lic k O
S et rslssu e " '"N ew A D O D B .R eco rd set
rslssu e.O p cn " select * fro m tb lT ra n sa ctio n " , D B C o n .co n d b , a d O p e n S ta tic , a d L o ck O p tim istic
rslssu c.A d d N cw
rs ls s u e .fie ld s (" M e m _ ID " ) ~ V a l(lx tM c m (O ).T e x t)
rs ls s u e .fie ld s (" B o o k _ ID " ) ~ V a l(tx tM e m ( I ).T e x t)
rs ls s u e .lie ld s (" D a te _ Is s u e " ) ~ C D a te (tx tM e m (2 ).T e x t)
rslssu e. U p d a te
A d d N cw T ra n = T ru e
rslssu e.M o v eL a st
U n lo a d Me

End Sub

P riv a te S u b F o rm _ L o a d O
tx tM e m (2 ).T e x t ~ D a te
A d d N e w T ra n ~ F a ls e
End Sub

P riv a te S u b L a b e l8 _ C lic k O

End Sub

P riv a te S u b rslssu c_ M o v eC o m p lete(B y V a l a d R ca so n A s A D O D 1 3 .E v en tR ea so n E n u m , B y V a l p E rro r


A s A D O D B .E rro r, a d S ta tu s A s A D O D B .E v en tS ta tu sE n u m , B y V a l p R eco rd sct A s A D O D B .R eco rd sct)
D im D a teR et A s D a te
D im rsR et A s N ew A D O D 1 3 .R eco rd set

If A d d N e w T ra n ~ T ru e T h e n

D a te R e t ~ D a te A d d (" d " , m o d C o n tro l.B o o k D a y s , rs ls s u e .lie ld s (" D a te _ ls s u e " » )

M sgB ox " Y o u r Is s u e ID : "+ C S tr(rs ls s u e .fic ld s (" T ra n s _ ID " )). v b O K O n ly , m o d C o n tro l.m s g T itle
M sg B o x " Y o u h a v cto retu rn b o o k o n o r b efo re" + C S tr(D a teR et) + ". O th erw ise y o u h a v e to p a y
fin e " + C S tr(m o d C o n tro l.F in e A m t) + " Tk. p e rd a y " , v b O K O n ly , m o d C o n tro l.m s g T itlc
) A ddN ew T ran = F alse
rsR e t.O p e n "S E L E C T ' FROM tb lR e tu rn " , D B C o n .c o n d b , a d O p e n S ta tic , a d L o c k O p tim istic
rsR cL A ddN ew
rsR ct.ficlds("T ran _'D " ) = rslssuc.ficlds( "T rans_10")
rsR eL fields("D atc_R ctum ") = D atcR et
rsR et.U pdatc

r s R e L C lo s c
Set rsR ct = N othing
E n d If
End Sub

P r iv a te S u b tx tM e m _ K e y P r e s s (ln d c x I\s In te g e r , K e y A s c ii A s In te g e r )

If In d e x ~ 0 A n d K e y A sc ii ~ 13 T hen
D im rsM em F ind A s A D O D B .R ccordset

Set rsM em F ind = N ew R ccordsct


rsM em F ind.O pcn "Select'" from tblM em bcrD ctails w here M cm bcf_ID =" &
T rim (txtM em (O ).T ext), D B C on.condb, adO pcnStatic, adL ockO ptim istic

If rsM cm F ind.R ecordC ount <= 0 T hen


M sgB ox "Y ou cnter \\'T o n g m em ber ID , P lease E nter C orrect T hen T ry", vbO K O nly,
m o d C o n tr o l.m s g T itle
tx tM e m ( In d e x ). S e tF o c u s
E lse
L a b e l2 .V is ib le = T ru e
tx tM e m ( I ).V isib le ~ T ru e
c r n d B o o k F in d . V is ib le = T ru e
tx tM e m (2 ). V isib le ~ T ru e
L abel3. V isible = T rue
L a b c l4 .V isib le ~ T ru e
E n d if
E n d If
End Sub

R etu rn B ook .frm

O ption E xplicit
D im rsB o o k A s A D O D B .R c c o rd se t
D im rsM em A s A D O D B .R ecordset
D im rsT ra n A s A D O D B .R e c o rd se t
D im rsR etum A s A D O D B .R ecordset
D im F ine A s Single

P riv a te S u b c m d C lo se _ C lic k O
U n lo a d M e
End Sub

P riv a te S u b c m d O K _ C lic k O
D im rsF ine A s A D O D B .R ccordset

If F in e > 0 T hen
Set rsF ine = N ew A D O D B .R ecordset
rsF inc.O pen "select'" from tbIF inc", D B C on.condb, adO penStatic, adL ockO ptim istic
rsF inc.A ddN ew
rsF in e .fie ld s(" M e m _ ID " ) ~ V a l(m c m F ie ld (O ).T e x t)
rsF in c .fic ld s(" T ra n _ ID " ) ~ rsR e tu rn .!ie ld s(" T ra n _ ID " )
rsfin c .tie ld s(" R e t_ ID " ) = rsR e tu m .tie ld s(" R e tu rn _ ID " )
rsF inc.ficlds(U F ineA m ount") = F ine

• x •
)
)
rsfin c.ficld s(n D a tc_ F in e" ) = D a te
rs F in e .U p d a te
E n d If
U n lo a d Me

End Sub

P riv a te Sub C om m and 1 _ C lie k O


F ra rn e4 .V isib lc = T ru e
End Sub

P riv a te Sub C om m and2 _ C lick O


D im rsF in d T ra n A s N ew A D O D B .R eco rd set
rsF in d T ra n .O p en " S elect'" fro m tb lT ra n sa ctio n w h ere M cm _ ID =" & T rim (T cx t1 .T cx t) & " O rd er
b y T ra n s_ ID " , D B C o n .co n d b , a d O p en S ta tic, a d L o ck O p tim istic

Ifrs F in d T ra n .R e e o rd C o u n t> 0 T hen


rsF in d T ra n .M o v eL a st
lx lM e m (O ).T e x t ~ rs F in d T ra n .lie Id s (" T ra n s _ ID " )
tx tM e m (O ).S e tF o e u s
F r a m e 4 .V isib le = F a lse
E ls e

M sg B o x " Y o u en ter w ro n g m em b er 1 0 " , v b O K O n ly , m o d C o n tro l.m sg T itle

E n d If

End Sub

P riv a te Sub Fonn _ L oadO

End Sub

P riv a te S u b tx tM em _ K cy P rcss(ln d ex A s In teg er, K ey A scii A s In teg er)

IfIn d e x ~ 0 A n d K e y A s c ii ~ 13 T hen
D im rsM em F in d A s A D O D 1 3 .R eco rd set
Dim days As Integer

S et rsM em F in d = N ew R eco rd set


rsM cm F in d .O p cn " S elect'" fro m tb lR ctu m w h ere T ra n _ ID =" & T r im (tx tM e m (O ).T e x t),
D B C o n .co n d b , a d O p en S ta tic, a d L o ck O p tim istic

IfrsM cm F in d .R cco rd C o u n t < = 0 T h en


M sg B o x " Y o u en ter w ro n g T ra n sa ctio n ID , P lea se E n ter C o rrect T h en T ry " , v h O K O n iy ,
m o d C o n tro l.m sg T itJ e
tx tM c m (ln d c x ).S c tF o e u s
E ls e

'R etu rn P a rt
S et rsR etu rn = N ew A D O D B .R eco rd set
rs R e tu rn .O p c n " S e le c t' fro m tb lR e tu rn w h e re T ra n _ ID ~" & T rim (tx tM e m (O ).T e x t),
D B C o n .co n d b , a d O p en S ta tic, a d L o ck O p tim istic
rs R c tu rn .fic ld s (" D a tc _ R c tu rn " ) ~ D a te
rsR etu m .U p d a te

S et rsT ra n = N ew A D O D 1 3 .R eco rd sct

rsT ra n .O p en " S elect * fro m tb lT ra n sa ctio n w h ere T ra n sJ D =" & rsR etu rn .fieJ d s(" T ra n _ ID " ).
D B C o n .c o n d b , a d O p e n S ta tie , a d L o c k O p tim is tie

- x i-
IssueField(O ).Tcxt ~ rsTran./ields("D atc_Issuc")
IssueFicld( I ).Tcxt ~ D ate

days ~ D ateD iIJ("d", rsTran./ields("D atc_lssuc"), D ate)

If d ays> m o d C o n t r o l.l3 o o k D a y s T hen

F in e = (d ays - m o d C o n tro J.B o o kD ays) * m o d C o n tro l.F in cA m t


Else
F in e = 0
End If

IssucField(2).Text ~ Fine

'M e m b e r part

S et rsM em = N ew A D O D B .R c c o r d s e t

r s M e m .O p e n " S e le c t * fr o m tb lM e m b c r D e ta ils w here M em b cr_ID =" &


t1

r s T r a n .f ie ld s ( M e m _ I D " ) , D B C o n .c o n d b , a d O p e n S ta tic , a d L o c k O p tim is tic


m em Ficld(O ).Text ~ rsM em ./ields("M em ber_ID ")
m em Field(1 ).Text ~ rsM em ./ields("M cm _N am e")

, Book Part
S et rsB ook = N ew A D O D B .R e c o r d s e t

rsB o o k.O p en "S elect * fro m tb IB o o kD ctails w h ere B o o k_ID =" & rs T ra n .tie ld s ("B o o k _ ID "),
D BCon.condb, adO penStatic, adLockO ptim istic
BookField(O ).Text ~ rsBook./ields("Book_lD ")
BookField( I ).Text ~ rsBook./ields("Book_N am e")
BookField(2).Text ~ rsBook./iclds("A uthor")
BookField(3).Text ~ rsBook.lields("Book_ Type")
BookField(4).Tcxt ~ rsBook.liclds("Publication")

End If
End If
End Sub

- xii -

You might also like