citizens registration management system - chapter four
DESCRIPTION
A thesis submitted to the Canadian Sudanese Collegein partial fulfillment of the requirements forB.Sc. in Computer Information SystemsTRANSCRIPT
CHAPTER
FOUR
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
36
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
IMPLEMENTATION
PREFACE: The purpose of this phase (also called the coding or development phase) is to
convert the system design into source code, or in other words workable
solutions (programs).
4.1 DATABASE IMPLEMENTATION
Database Implementation or Physical Database Design is the process of
producing a description of the implementation of the database on secondary
storage; it describes the base relations, file organizations, and indexes design
used to achieve efficient access to the data, and any associated integrity
constraints and security measures. [10]
The following approach was used in the physical database design:
Tables
o Every entity has a primary key, as needed by entity integrity
constraint.
o Basic tables are created first to avoid pitfalls of referential integrity
and all columns of the basic tables are set to UNIQUE KEY to
avoid duplicates.
o Transaction tables are created with constraint on foreign keys (ON
UPDATE CASCADE ON DELETE RESTRICT) to avoid making
a record unreachable.
o All foreign keys are indexed to make references easier
Users
o ‘Staff’ Users (i.e. users with staff role as illustrated in the Use Case
diagram in Chapter Two) are only given SELECT, INSERT,
UPDATE privilege on all tables, except basic tables and Notes
table which were given additional DELETE privilege.
o ‘Admin’ User has full DBA privileges
[See Appendix C]
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
37
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
4.1.1 DATA TYPES DESCRIPTION
Name Sql
Standard? Length Range Size Description
Char Yes Fixed 0 – 255 Length * 1
byte
The ASCII
character set uses
one byte to store
each character,
whereas the
Unicode character
set uses up to four
bytes per character.
Using Char as
opposed to VarChar
leads to larger
tables, but usually
faster processing,
because MySQL
knows exactly
where each record
starts
VarChar Yes Variable 0-255 1 byte per
character
The ASCII
character set uses
one byte to store
each character,
whereas the
Unicode character
set uses up to four
bytes per character.
Enum No
Fixed
(Differe
nt
definitio
ns will
have
different
lengths;
however
,
these
lengths
are fixed
once the
field is
defined.)
1–65,535 enumerated strings
1–255
enumerated
strings = 1
byte,
256–
65,535
enumerated
strings = 2
bytes
Enum (Enumerate)
data type is used for
limiting contents of
a column to one
choice.
Combination of
strings in the
enumerated list can
be stored as a
comma-delimited
list You can also
perform queries on
enumerated fields
based on their
indexes (the first
value starts at 1).
Enumerated fields
are sorted on their
index values, not
alphabetically. In
other words, they
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
38
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
are sorted in the
order the values
were defined.
Text No Variable Max. 64KB Length + 2
bytes
It can contain more
text, the size
increases as the text
increase. The
additional 2 bytes
store length
TinyInt No Fixed -128 – 127 (Signed)
0 – 255 (Unsigned) 1 byte
All values are saved
in 1 byte
Int Yes Fixed
–2,147,483,648 –
2,147,483,647(Signed)
0 – 4,294,967,295(Unsigned)
4 bytes It stores only
decimal numbers
Date Yes Fixed ‘1000-01-01’ – ‘9999-12-31 3 bytes It only stores date
value.
DateTime Yes Fixed ‘1000-’01-01 00:00:01’ –
‘9999-12-31 23:59:59’ 8 bytes
It stores date value
and time.
TimeStamp Yes Fixed ‘1970-01-01 00:00:00’ –
‘2038-01-18 22:14:07’ 4 bytes
It is the only
Datetime data type
in MySQL v5.1 that
supports automatic
time stamping upon
update or insertion.
MediumBlob No Variable Max. 16MB Length + 3
bytes
It stores all type of
data (multimedia,
text strings, etc) in
bytes string. The
additional 3 bytes
store length.
Table 4.1.1- Database Data Types Description
Note: by default all tables created by MySQL are static tables, unless it contains
any of the data type with Variable length.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
39
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
4.2 USER INTERFACE
The User Interface portion of a software product is responsible for all
interactions with the user. Almost every software product has a User Interface.
In the early days of the computer, no software product had any User Interface
because the computers those days were batched systems and no interactions
with the users were supported.
The User Interface is the primary component of any software product that is
directly relevant to the users. Many users often judge a software product from
the User Interface. An interface that is difficult to use leads to higher levels of
user errors and user dissatisfaction. Users feel frustrated when a system behaves
in unexpected ways, i.e. when the issued commands do not carry out actions
according to intuitive expectations to the user. [3]
Normally, when a user starts using a system he builds a mental model of the
system and expects the system to conform to it. For example, if a user action
causes one type of system activity and response under some context, then the
user would expect similar response from other actions with same context.
Therefore, sufficient care and attention was taken to give the user a consistent
commands context.
In this system, pre-emptive mechanisms were taken to prevent as much user
errors as possible from occurring. A complex validation algorithm was used to
ensure that data inputted by user is in correct format and consistent. Every text
box has a maximum character length which corresponds with the same field size
in the database (except for fields that were not given a predefined character
limit, for example Notes and Job History fields), this prevent the user from
feeding in data that is beyond the field in the first place – which generally saves
user time and decreases error rate. A Server-Client validation approach was
used to validate data, which tries as much as possible to prevent insertion of
invalid data.
When designing the User Interface some features were put at top priority:
The system is not only suppose to do what it is supposed to do, but it has
to do it right. Moreover, it has to be done by whom is only authorized to
do it.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
40
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
A good Graphical User Interface with easy: speed of learning; speed of
use; speed of recall; consistent commands; attractive and appealing; and
that can support multiple skill levels.
A Graphical User Interface that provide user with feedback periodically
informing him that his request is been processed or is in progress.
4.2.1 USER INTERFACE SCREENSHOTS
Fig 4.1 – Login screen as the system is started, indicating to the user where to
insert his username as he hover his mouse over the username field.
Fig 4.2 – Login screen – showing warning message as the user entered invalid
username / password combination
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
41
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.3 Login screen – The system is closing after 3 invalid login attempts
Fig 4.4 Main screen window (for users with staff role only) - at first start,
showing total number of: active citizens; dormant citizens; valid passports;
expired passports at the status bar.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
42
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.5 Log window - showing the successful and unsuccessful login attempts
to the system with date and time.
Fig 4.6 Change password dialog - it gives the user (with staff role) the freedom
to change his password whenever he feels like changing or when he thinks his
password has been compromised.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
43
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.7 Authority Window - showing list of passport authorities. All basic tables
has the same type of window
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
44
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.8 Registration Form – the first name field is highlighted in red as the user
press save while the field is empty. Each field will highlight to red if invalid
data is inputted upon pressing save to tell the user the exact field that has
incorrect values.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
45
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.9 Registration Form – a dialog box showing a citizen is saved successfully
with his new registration number after all data has been validated
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
46
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.10 Viewing Window – a citizen is viewed with all his records bundled in
one place
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
47
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.11 Citizen Registration Information & Remarks ready to be printed
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
48
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.12 Search Dialog – telling the user to select a search criterion
Fig 4.13 Report Dialog – telling the user to select a report criterion
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
49
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.14 Sample of list report been generated using marital status (single)
criterion
Fig 4.15 Report sample been exported to Microsoft Excel directly from the
application. It can also be exported to pdf format for extensibility.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
50
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.16 Sample of Graph (pie chart) Report been generated using marital status
(single) criterion
Note: All graph reports with 4 or less variables (like Gender, Marital Status and
Activity Status) are generated using pie chart, while others with more variables
are generated with bar chart.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
51
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.17 Sample of Graph (bar chart) Report been generated using State of
Origin criterion
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
52
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.18 Administrator Main Window (for users with Administrator role only) –
showing a new user with staff privilege is about to be created.
Note: In the current version of MySQL v5.1, the username has a maximum
length of 16 characters, while the password has a maximum length of 41
characters.
Chapter Four: Implementation – Nigerian Citizens Registration Management System in Sudan
53
By Suleiman Umar Abdullahi, supervised by Dr. Awad Mohamed
Fig 4.19 Administrator Main Window – showing list of all users with their
usernames and roles.