0% found this document useful (0 votes)
71 views21 pages

Database Project

database project

Uploaded by

yoftijephthah
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)
71 views21 pages

Database Project

database project

Uploaded by

yoftijephthah
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/ 21

lOMoARcPSD|50409653

Database Project SEC-2 Nrssyr

database (Addis Ababa Institute of Technology)

Scan to open on Studocu

Studocu is not sponsored or endorsed by any college or university


Downloaded by Yofti Jephthah ([email protected])
lOMoARcPSD|50409653

ADDIS ABABA INSTITUTE OF TECHNOLOGY


University
Department of Software Engineering
SECTION - 2
Database Group Project
NAME : ID

1. NATNAEL WONDIMU……………….ATE /7632/13


2. REDIET ABAHNEH ………………….ATE/4060/13
3. SOLOMON MEKONEN ………………ATE/3696/13
4. SEADA ADNAN………………………..ATE/2575/13
5. YARED YIRGALEM……………………ATE/9061/13
6. REHOBOTH MELAKU…………………ATE/1745/13

SUBMITTED TO :
DR KASSAHUN

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

Police Criminal
Database

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

CONTENTS

INTRODUCTION...........................................................................................................................................1
CONCEPTUAL DESIGN..................................................................................................................................2
ENTITY RELATION DIAGRAM........................................................................................................................4
RELATIONAL MODEL....................................................................................................................................5
PHYSICAL DESIGN........................................................................................................................................8
PHYSICAL DATA MODEL.............................................................................................................................10
Appendix......................................................................................................................................................I
SQL CODE..................................................................................................................................................I

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

INTRODUCTION

One of the most important issues that exist on a global scale is crime. In our nation, crime rates
have been rapidly increasing. Understanding the causes of crime will help control it. This
requires that crimes be thoroughly documented, examined, and, as a result of the analysis's
findings, resolved with workable solutions.
The current data handling method in police stations in our country is manual file handling
system, computerized data handling systems are rare. Even though it provides good security, it
has a number of limitations. Some major limitations are:
-Data organization
-Data efficiency
-Updating, Retrieving, and Integrating file
-Cross referencing of data
-It is prone to error
-Requires more human labor
Since the current data management is manually, it is stored in one or more cabinets.
Organization of data is by using index system, it is a system in which a data is accessed easily by
identifying the location by file name, key data fields in a database, or through a text in a file.
Data are searched and retrieved by either searching the right cabinet then the right file then the
information.
Generally, database system’s advantage over the manual system can be easily distinguished
because it literally improves the drawbacks on manual file handling system. This can be
measured by; simple and effective organization of data; data can be easily updated, retrieved,
and integrated; it is more centralized hence will provide much better information control;
database system requires less labor in comparison with manual system. Even though manual file
handling system provides a good security, database system has much better security system. So
the simplicity and effectiveness of database system over manual system generally explains the
measurement of benefits.
The Police Database is an information management system that improves the ability of the
Police Service to manage and share intelligence and other operational information, to prevent
and detect crime and make communities safer. The Police Database offers a capability for the
Police Service to share, access and search local information electronically, overcoming artificial
geographical and jurisdictional boundaries.

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

The database system is made to:


1. Provide an online tool for crime management that is available to everyone.

2. Enhance crime analysis and reduce paperwork

3. Offer back-up and security

4. Ensure data integrity

5. By submitting information online, you can save time and labor.

When there is a First Information Report for a crime, police can add information to the
database. They can upload more data to the system when they discover and acquire more
details about the crime. Both recent crimes with little information and older crimes with lots of
information can be stored in it. Therefore, it also offers versatility. The police can also use this
system to quickly fill out crime reports, traffic(accident) reports and administrative reports.
The software utilizes a client-server architecture. Users (clients) with access rights to the server
can examine the data that has already been saved, add new data, and update the data in
accordance with their level of access rights. All of the information concerning crime is in the
database on the server side. Prototyping the relational database system is the main goal of this
work.
Smartphones, tablets, and PCs can all be used to access the database system. Any browser can
be used by the client to login to the system. SQL Server 2019 or 2020 Express will be installed on
the server.

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

CONCEPTUAL DESIGN

The entities with their respective attributes as follows:-

1. Case:

The issue to be investigated by the police, and resolved by the court. It has
attributes like case id, officer id, FIR number, law number, detail, status.

Relations- A case is investigated by an officer.

- A case has first investigation report.

2. Crime:

The offense to be punished by law. It has attributes like crime id, FIR number,
crime name, crime type, date occurred, time occurred, city, sub city, kebelle.

Relation - first investigation report is filed for a crime.

3. Victim:

The person harmed, injured, or killed as a result of a crime. It has attributes like
victim id, NID, first name, middle name, last name, sex, birth date, nationality,
education, nationality.

Relation- first investigation report is filed for a victim.

4. Accused:

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

The person who is charged with crime. It has attributes like accused id, NID, first
name, middle name, last name, sex, nationality, education, occupation, status.

Relations- accused person is also listed as wanted.

- First investigation report is filed against accused person.

5. Wanted:

The accused, wanted by police. It has attributes like wanted id, height, scar, most
wanted, detail.

Relation- a wanted person is accused of committing a crime.

6. Petitioner:

The person who complaints under the jurisdiction of police. It has attributes like
NID, first name, middle name, last name, city, sub city, kebelle, house no, phone
number.

Relation- first investigation report is filed or filled by a petitioner.

7. FIR:

First Information Report, written by the police after they gather information from
the petitioner about the criminal case. It has attributes like FIR no, NID, date
reported, time reported, detail.

Relations- A case has first investigation report.

- first investigation report is filed for a crime.


- first investigation report is filed for a victim.
- First investigation report is filed against accused person.

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

- first investigation report is filed or filled by a petitioner.

8. Officer:

The police officer who makes investigation on the case. It has attributes like officer
id, first name, middle name, last name, rank.

Relation- officer investigates a crime case.

ENTITY RELATION DIAGRAM

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

RELATIONAL MODEL

Table name officer

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

Officer_ ID First_ Name Middle_ Name Last_ Name Rank


1000045 Girma Tola Habtamu Hamsa aleka
1000064 Dawit Tadele Alemayehu Officer
1000056 Tolosa Kebede Belay Detective

Officer_ ID ⟶ {First_ Name, Middle_ Name, Last_ Name, Rank}

Normal Form: 3NF

Table name FIR

FIR_ No NID Date_ Reported Time_ Reported Detail


1 6387478923 04/12/2014 03:14 Domestic violence
2 2356929849 04/12/2014 11:36 Rape
3 3287469380 04/12/2014 12:52 Robbery

FIR_ No ⟶ {NID, Date_ Reported, Time_ Reported, Detail}

Normal Form: 3NF

Table name petitioner

NID First_ Middle Last_ City Sub_ Kebelle House Phone_ no


Name _ Name city _no
Name
142432445 Nathnae Melaku Abebe Addis Akaki 12 435 095641233
2 l ababa kality 2
532667475 Hiwot Mesfin Tadesse Addis Akaki 12 546 095365896
7 ababa kality 8
346534756 Kalab Kebede Tesema Addis Akaki 12 753 093546218
4 ababa kality 6

NID ⟶ {First_Name, Middle_Name, Last_Name, City, Sub_city, Kebelle, House_no, Phone_no}

Normal Form: 3NF

Table name victim

Victim NID First_ Middle_ Last_ Se Birth_ Nationali Educatio Occupatio


_ ID Name Name Name x Date ty n n

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

1 35464878 Kalkida Gizache Tasew F 22/05/19 Ethiopia Degree Unemploy


76 n w 89 n ed
2 54648976 Henok Taye Kasahu M 12/12/19 Ethiopia Highscho Unemploy
45 n 95 n ol ed
3 54164869 Aster Yohann Girma F 19/06/19 Ethiopia Degree Merchant
45 es 91 n

Victim_ ID is not same as the NID. One person can be victim in several times and cannot take
the same Victim_ ID twice or more. Victim_ ID is generated while a FIR is reported.

Victim_ ID ⟶ {NID, First_ Name, Middle_ Name, Last_ Name, Sex, Birth_ Date, Nationality,
Education, Occupation}

Normal Form: 3NF

Table name accused

Accuse NID First_ Middl Last_ Se Birth_ Nationa Educati Occupa Status
d_ ID Nam e_ Name x Date lity on tion
e Name
1 5646896 Yona Habta Haile M 16/08/1 Ethiopia Highsch Driver Wante
512 s mu 985 n ool d
2 8975654 Mikiy Worku Belay M 05/11/1 Ethiopia Masters Teacher Releas
612 as 990 n ed
3 4687898 Hele Fikadu Hailesl F 29/01/1 Ethiopia Diplom Secretar Arrest
998 n ase 986 n a y ed

Accused_ ID is not same as the NID. One person can be accused in several times and cannot
take the same Accused_ ID twice or more. Accused_ ID is generated while a FIR is reported.

Accused_ ID ⟶ {NID, First_ Name, Middle_ Name, Last_ Name, Sex, Birth_ Date, Nationality,
Education, Occupation, Status}

Normal Form: 3NF

Table name crime

Crime_ FIR_ No Crime_ Crime_ Date_ Time_ City Sub_ Kebelle

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

ID Name Type Occurred Occurred City


1 954 Illegal Victim 23/08/201 12:00 Addis Akaki 12
drug less 4 ababa kality
trafficking crime
2 1528 Robbery Property 09/11/201 04:30 Addis Akaki 13
crime 4 ababa kality
3 658 vandalis Property 21/01/201 01:45 Addis Akaki 12
m crime 4 ababa kality

Crime_ ID ⟶ {FIR_ No, Crime_ Name, Crime_ Type, Date_ Occurred, Time_ Occurred, City,
Sub_ City, Kebelle}

Normal Form: 3NF

Table name case

Case_ ID Officer_ ID FIR_ No Law_ No Status Detail


1 1000023 546 45689 Closed Criminal
caught
2 1000078 1345 54612 Open Evidence
collecting
3 1000099 1223 85645 open Searching for
suspects

Case_ ID ⟶ {Officer_ ID, FIR_ No, Law_ No, Status, Detail}

{Officer_ ID, Law_ No} ⟶ {Case_ ID, FIR_ No, Status, Detail}

Normal Form: 3NF

Table name wanted

Wanted_ ID Height Scar Most _Wanted Detail


1 1.74 No 1 Disappeared
2 1.56 No 0 Last seen on
22/11/2014
3 1.82 Chin 0 Often goes to
clubs

Wanted_ ID ⟶ {Accused_ ID, Height, Scar, Most_ Wanted, Detail}

Accused_ ID ⟶ Wanted_ ID

Normal Form: BCNF(Boyce- Codd normal form)

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

PHYSICAL DESIGN

N Name of entity Notation Attributes(constraints) Data type


o
1 Officer Officer Officer_ ID(primary Integer
key)
First_ Name Varchar
Middle_ Name Varchar
Last_ Name Varchar
Rank varchar

2 First information report FIR FIR_ No(primary key) Integer


NID(foreign key) Integer
Date_ Reported Varchar
Time_ Reported Varchar
Detail varchar

3 Petitioner Petitioner NID(primary key) Integer


First_ Name Varchar
Middle_ Name Varchar
Last_ Name Varchar
City Varchar
Sub_ city Varchar
Kebelle Integer
House _no Integer
Phone_ no Integer

4 Victim Victim Victim_ ID(primary Integer


key)
First_ Name Varchar
Middle_ Name Varchar
Last_ Name Varchar
Sex r
Birth_ Date Varchar
Nationality Varchar
Education Varchar
Occupation Varchar

5 Accused Accused Accused_ ID(primary Integer


key)
NID Integer
First_ Name Varchar
Middle_ Name Varchar
Last_ Name Varchar

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

Sex Char
Birth_ Date Varchar
Nationality Varchar
Education Varchar
Occupation Varchar
Status Varchar

6 Crime Crime Crime_ ID(primary Integer


key)
FIR_ No(foreign key) Integer
Crime_ Name Varchar
Crime_ Type Varchar
Date_ Occurred Varchar
Time_ Occurred Varchar
City Varchar
Sub_ City Varchar
Kebelle Varchar

7 Case Case Case_ ID(primary key) Integer


Officer_ ID(foreign Integer
key)
FIR_ No(foreign key) Integer
Law_ No Integer
Status Varchar
Detail Varchar

8 Wanted Wanted Wanted_ ID(primary Integer


key)
Height Float
Scar Varchar
Most _Wanted bool
Detail Varchar

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

PHYSICAL DATA MODEL

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

 Backup servers will be available for the database system. Each piece of data
from the primary servers will be replicated on these servers. The backup
servers are employed when the primary servers malfunction or when data
recovery is required.
 Rank and access levels determine the privileges that users of this system
have. Users must enter their username and password in order to log into
the system, which is done for security reasons.
 The system can eventually incorporate AI to improve efficiency. Facial
recognition and image enhancement technologies can be used to solve
cases more quickly thanks to the integration of AI with the police database
system.

Appendix primary key(case_id));

SQL CODE
create table petition(NID int,
create database police_station; first_name varchar(50),
use police_station; middle_name varchar(50),
create table officer(officer_id int, last_name varchar(50),
first_name varchar(50), city varchar(25),
middle_name varchar(50), sub_city varchar(25),
last_name varchar(50), kebelle int,
ranking varchar(50), house_no int,
primary key(officer_id)); phone_no varchar(10),
primary key(NID));
create table cases(case_id int,
officer_id int,
FIR_no int,
law_no int, create table FIR(FIR_no int,
case_status varchar(100), NID INT,
detail varchar(100), date_reported date,

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

time_reported time, occupation varchar(100),


detail varchar(100), primary key(victim_id));
primary key(FIR_no)); create table crime (crime_id int,
FIR_no int,
create table accused (accused_id int, crime_name varchar(100),
NID int, crime_type varchar(100),
first_name varchar(50), date_occured date,
middle_name varchar(50), time_occured time,
last_name varchar(50), city varchar(25),
sex char, sub_city varchar(25),
birth_date date, kebelle int,
nationality varchar(50), primary key(crime_id));
education varchar(100),
occupation varchar(100), create table wanted (wanted_id int,
accused_status height float,
varchar(100),
scar varchar(50),
primary key(accused_id));
most_wantded bool,
detail varchar(100),
create table victim(victim_id int,
primary key(wanted_id));
NID int,
first_name varchar(50),
middle_name varchar(50),
last_name varchar(50),
sex char,

birth_date date,
nationality varchar(50),
education varchar(100),

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

alter table cases add foreign key(officer_id) references officer(officer_id) on delete set null;
alter table cases add foreign key(FIR_no) references FIR(FIR_no) on delete set null;
alter table crime add foreign key(FIR_no) references FIR(FIR_no) on delete set null;

insert into officer value("100045","Girma","Tola","Habtamu","Hamsa aleka");


insert into officer value("1000064","Dawit", "Tadele" ,"Alemayehu", "Officer");
insert into officer value("1000056","Tolosa","Kebede" ,"Belay","Detective");
insert into FIR value("1","638747","2014-02-14","03:14","Domestic violence");
insert into FIR value("2","235692","2014-12-04","11:36","Rape");
insert into FIR value("3","328746","2014-12-04","12:52","Robbery");
insert into petition value("142432","Nathnael", "Melaku" ,"Abebe" ,"Addis ababa","Akaki
kality","12","435","0956412332");
insert into petition value("532667","Hiwot","Mesfin", "Tadesse" ,"Addis ababa","Akaki
kality","12","546","0953658968");
insert into petition value("346534","Kalab", "Kebede", "Tesema","Addis ababa", "Akaki kality",
"12","753","0935462186");
insert into victim value("1","354648","Kalkidan", "Gizachew", "Tasew" ,"F", "1989-05-
22","Ethiopian", "Degree" ,"Unemployed");
insert into victim value("2","546489","Henok","Taye","Kasahun", "M" ,"1995-12-
12","Ethiopian", "Highschool" ,"Unemployed");
insert into victim value("3","541648","Aster","Yohannes", "Girma" ,"F","1991-06-
19","Ethiopian","Degree","Merchant");
insert into accused value("1","564689","Yonas", "Habtamu" ,"Haile", "M", "1985-08-
16","Ethiopian", "Highschool","Driver","Wanted");
insert into accused value("2","897565", "Mikiyas" ,"Worku" ,"Belay" ,"M" ,"1990-05-
11","Ethiopian" ,"Masters","Teacher" ,"Released");
insert into accused value("3","468789", "Helen" ,"Fikadu" ,"Haileslase" ,"F" ,"1986-01-29",
"Ethiopian" ,"Diploma" ,"Secretary"," Arrested");
insert into crime value("1",null,"Illegal drug trafficking","Victim less crime", "2014-08-
23","12:00", "Addis ababa"," Akaki kality","12");
insert into crime value("2",null,"Robbery", "Property crime", "2014-11-09","04:30","Addis
ababa","Akaki kality", "13");
insert into crime value("3",null,"vandalism","Property crime", "2014-01-21","01:45","Addis
ababa", "Akaki kality","12");

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

insert into cases value("1",null,null,"45689","Closed","Criminal caught");


insert into cases value("2",null,null,"54612","Open","Evidence collecting");
insert into cases value("3",null,null,"85645","open","Searching for suspects");
insert into wanted value("1","1.74",null,1,"Disappeared");
insert into wanted value("2","1.56",null,0,"Last seen on 22/11/2014");
insert into wanted value("3","1.82","Chin", 0,"Often goes to clubs");

Downloaded by Yofti Jephthah ([email protected])


lOMoARcPSD|50409653

SOME OF THE QUERY


TABLES FROM THE
SQL CODE..

Downloaded by Yofti Jephthah ([email protected])

You might also like