Database For Criminal Record Management System
Database For Criminal Record Management System
Muhammad Rizwan
Faheemullah
Kamran Ali
Contact : mrizwan969@gmail.com
Introduction
Police provides safety to citizens. It always remains steady for arresting any
criminal who is a threat for the safety of society. After registering the FIR
from any citizen, police starts its work and on that basis it arrests the
criminals if proofs are found against them. Once the criminals are arrested,
police starts investigation from them. After getting all the proofs against the
criminal, it is the duty of the police to present all the proofs honestly to the
court so that the right man can get right punishment. The true and right
information provided by the people to police helps a lot in arresting the
criminals who try to spoil the peaceful environment of society.
Contact : mrizwan969@gmail.com
ENTITIES
These are the entities of CRMS.
1. Petitioner
2. Victim
3. Accused
4. FIR
5. Case
6. Investigation Officer
Petitioner:
A person who is seeking legal help from police station or he has some
problem or complaints regarding the matters under the jurisdiction of police.
Petitioner may or may not be the victim of offense.
Victim:
"Victim" means an individual who suffers, in relation to an offence.
FIR:
First Information Report (FIR) is a written document prepared by the
police when they receive information from the Petitioner about the
commission of a cognizable offence.
Accused:
"Accused" means a person who is charged with an offence or crime.
Case:
Case is the issue to be investigated by the police and resolved by the
court.
Contact : mrizwan969@gmail.com
Investigation officer:
“Investigation officer” is the police officer who investigates the
case. There may be more than one investigation officers in one police
station.
ATTRIBUTES OF ENTITIES
Petitioner:
Definition:
A person who is seeking legal help from police station or he has some
problem or complaints regarding the matters under the jurisdiction of police.
Anyone who knows about the commission of a cognizable offence can file an
FIR. It is not necessary that only the victim of the crime should file an FIR.
A police officer who comes to know about a cognizable offence can file an FIR
Himself/herself.
You can file an FIR if:
1. You are the person against whom the offence has been committed
2. You know yourself about an offence which has been committed
3. You have seen the offence being committed.
Attributes:
The Petitioner has the following attributes
Name:
The full name of Petitioner.
Father_name:
Contact : mrizwan969@gmail.com
The father name of Petitioner.
Address:
Address of Petitioner.
Contact:
Contact number of Petitioner.
NIC:
Identifier:
NIC+NAME:
Contact : mrizwan969@gmail.com
Investigation officer:
Definition:
Every criminal case has an investigation officer who finds and examines the nature of the
case, witnesses and evidences to find the criminal.
Attributes:
Name:
The full name of the investigation officer.
Officer ID:
Every police officer has got some ID so the code or ID of investigation
officer is another attribute.
Rank:
The rank of an investigation officer.
Identifier:
Officer ID:
As every police officer has a unique ID so we can take officer ID as an
identifier.
Contact : mrizwan969@gmail.com
Case:
Definition:
A file in which daily detail of a case are written down by the investigating
officer
The police may not investigate a complaint even if you file a FIR, when:
(ii) The police feel that there is not enough ground to investigate. However,
the police must record the reasons for not conducting an investigation and in
the latter case must also inform you.
Attributes:
Case ID:
Each case is assigned an ID.
Section_of_law :
Through section of law we can find a lot about nature of the case E.g.
the criminal act and its sentence accordingly.
Case Status:
It’s another attribute of entity case, through which we can find whether
the case is closed or open.
Case detail:
The detail of the case is written here.
Identifier:
Case ID:
Contact : mrizwan969@gmail.com
Since each case has its own unique identifier which is it’s ID so we take
case ID as an identifier, which can never be an unknown value.
Accused:
Definition:
Accused is the person who commits a crime. It is the most important
entity in our DB because our whole project is based upon this entity. So
that’s why is also related to most of the entities. And also we are concerned
with most of its attributes to watch an accused as easily as possible.
Attributes:
Accused_ID:
It is assigned by the police department whenever a perosn either guilty
or not suffers from police investigation or in any sort of procedures remains
unique for the whole life
Name:
In this attribute the name against an accused id is entered.
Father_Name:
In this attribute the Father’s name against an accused id is entered.
Alias:
Alias is the nick name sort of thing which is popular among the people
and is very important these days because one accused usually is not known
Contact : mrizwan969@gmail.com
as his real name and has several nick names that’s why Alias is a
multivalued attribute.
Address:
In this attribute the expected or permanent address of accused is
saved. It is also multivalued because one may have many addresses.
NIC:
If the NIC of accused is known then it is saved in this attribute.
Gender:
Gender of accused.
Age:
The age of accused is entered in this attribute.
Status:
The status of accused is entered like either he is
Arrested,Escaped,Bailed or Released.
Contact:
It is composite attribute. In this attribute we list the mobile number or
land line number and email address of the accused.
Phone:
The phone number of the accused. It is multivalued attribute because
an accused can have more than one contact numbers.
Email:
The email id of the accused.
Photo:
The picture identity of the accused.
Contact : mrizwan969@gmail.com
Finger print:
The finger print of the accused stored for identification purpose.
Identifier:
Accused_ID:
Accused ID is the sole identifier for accused because all other
attributed becomes multivalued in case of dangerous criminals whose
identity is not confirmed. Once accused id is assigned to a criminal then we
start filing other available attributes.
FIR:
Definition:
First Information Report (FIR) is a written document prepared by
the police when they receive information about the commission of a
cognizable offence. It is a report of information that reaches the police first in
point of time and that is why it is called the First Information Report.
It is generally a complaint lodged with the police by the victim of a
cognizable offence or by someone on his/her behalf. Anyone can report the
commission of a cognizable offence either orally or in writing to the police.
Even a telephonic
message can be treated as an FIR.
Importance of FIR
An FIR is a very important document as it sets the process of criminal
justice in motion. It is only after the FIR is registered in the police station that
the police take up investigation of the case.
Contact : mrizwan969@gmail.com
Attributes:
FIR_ID:
Once FIR is longed against any sort of complaint an ID is assigned to it.
Date_lodged:
The date on which FIR is lodged.
Time_lodged:
The time of FIR being lodged.
Detail:
The detail of an FIR consists of following attributes.
Incident Place:
The place on which complained incident took place.
Incident Date:
The date on which complained incident took place.
Incident Time:
The time on which complained incident took place.
Identifier:
FIR_ID:
FIR ID is identifier of an FIR because it is kept in record of police
department filing that specific FIR against a compliant. So a specific ID will
always toward the unique incident.
Contact : mrizwan969@gmail.com
Victim:
Victim is a person is a person which is affected by any sort of activity
by the accused. He might be dead or alive due to the crime committed.
Attributes:
Name:
The name of the victim is entered in this attribute.
Father_Name:
Father name of accused person.
Address:
The address of the victim is entered in this attribute.
Contact:
The contact information of the accused is entered in this attribute like
phone# etc.
Identifier:
Name +Address:
One name can exist on more than one address, but it is not possible
that two persons with same name have same address.
RELATIONSHIPS BETWEEN
ENTITIES
Contact : mrizwan969@gmail.com
Petitioner and FIR
➢ Petitioner files an FIR
➢ There is one-to-many relationship between Petitioner and FIR
because
➢ One Petitioner can file more than one FIRs.
➢ But one FIR is filed by one and only one Petitioner.
➢ It is not possible that an FIR is lodged by unknown Petitioner.
➢ Hence we conclude that cardinality of Petitioner is mandatory
one.
➢ According to the definition of Petitioner it is necessary for a person to
be a Petitioner that he/she must file at least one FIR.
➢ Hence the cardinality of FIR is mandatory-many.
Contact : mrizwan969@gmail.com
FIR and Victim
➢ FIR is filed by Petitioner for a victim who is suffered from offence.
➢ There can be one or many victims for one FIR.
➢ There is one and only one FIR for a victim.
➢ Cardinality of FIR is mandatory one.
➢ Cardinality of victim is one-many.
Contact : mrizwan969@gmail.com
➢ Cardinality of FIR is mandatory one.
➢ Cardinality of case is optional one.
ER-Model
Contact : mrizwan969@gmail.com
RELATIONAL MODEL
Contact : mrizwan969@gmail.com
Investigation officer:
• Name and rank are attributes of entity investigation officer
Case:
• Case status , section of law ,case detail are the attributes and Case_ ID
is primary key of entity case
• Since it has one-to many relationship with FIR and Investigation officer
that is why FIR_ID and Officer_ id are added as foreign key attributes
in this relation
Petitioner:
• Father_name, Address and Contact are attributes and the NIC and
Name is primary key of Petitioner.
FIR:
• Date_ logged, Time_ Lodged, Incident_ time, Incident_ place, Incident_
date is attributes and FIR_ID is primary key of FIR.
• P_NIC and P _Name is foreign key since FIR has one to many
relationship with petitioner.
• Victim _Name and Victim _address is foreign key since FIR has one to
many relationship with Victim.
Contact : mrizwan969@gmail.com
Date Time Victi
Incide Incide Incide Victim
Petitioner Petitioner_N _ _ FIR_ m
nt_ nt_ nt_ _addre
_NIC ame lodg lodg ID _Nam
time Place date ss
ed ed e
Accused:
Name, Father_ Name, Status, Photo, Age, Email, Gender, and NIC is
attributes and Accused_ ID is primary key of accused, where as
accused Address, accused Phone and Accused Alias is multi valued
attributes of accused.
Accused_ Addres
ID s Accused_
Phone Accused_ Alia
ID
ID s
Accused_ Address:
Accused_ Phone: Accused_Alias:
Accused_
Alias:
Accused:
Nam Father_na Stat Phot Ag Gend Ema Finger_pr NI Accused FIR_I
e me us o e er il int C _ID D
Contact : mrizwan969@gmail.com
Victim:
• Father_ Name , contact is attributes of Victim and Name , Address is
the primary key.
Investigation officer:
Officer_ Name Rank
ID
Case:
Petitioner:
Time
Victi Incide
Petitio Petition _ Incide Incide
m Victim_add Date_Lod nt_ FIR_
ner er_ nt nt
_Nam ress ged ID
_NIC Name lodg _time _Place
e date
ed
Contact : mrizwan969@gmail.com
FIR:
Victim:
Name Address Father_ Contac
Name t
Accused
Phone
_ID
Accused:
Nam Father_na
Accused_ Stat Phot Ag Gend Ema Finger_pr NI Accused FIR_I
e me Alias o
us e er il int C _ID D
ID Accused_
Address
ID
Contact : mrizwan969@gmail.com
NORMALIZATION
Contact : mrizwan969@gmail.com
First Normal Form
All the tables in relational model are in 1NF because they fulfill the definition
of relation. i.e there are no multi-valued attributes
Investigation Officer:
• Name and Rank can be determined by officer_id (primary key)
Case:
Case_ Case_statu Case_Descri Section_of_l FIR_I Officer
ID s ption aw D _ID
Petitioner:
NIC Name Father_nam Address Contact
Contact : mrizwan969@gmail.com
e
Victim:
• Father_name and contact can be determined exactly if name and
address both are known because name is not unique similarly address
is also not unique but name+address collectively is unique
• Hence there is no partial functional dependency
Father_na
Name Address Contact
me
FIR:
• FIR_ID è Date_lodged , Time_lodged ,Incident_place, incident_date
Accused:
• Accused_IDèName,father_name,status,gender,age,nic,email
Accused_Address:
Accused_ID Address
Accused_Contact:
Accused_ID Phone_No
Accused_Alias:
Accused
_ID Alias
Contact : mrizwan969@gmail.com
All the other relations are in 3NF because there are no transitive
dependencies.
Contact : mrizwan969@gmail.com
PHYSICAL MODEL
Contact : mrizwan969@gmail.com
// paste physical model here
Contact : mrizwan969@gmail.com
IMPLEMENTATION
Contact : mrizwan969@gmail.com
SQL Implementation:
Note: All the following queries are written for Oracle XE so this SQL script
may need some variations while running on some other DBMS product
Petitioner_T:
CREATE TABLE Petitioner_T(
Father_name VARCHAR2(50),
Address VARCHAR2(100),
Contact NUMBER(12,0),
);
• Primary key is composed of NIC and Name that is why NOT NULL
constraint is applied to these columns
FIR:
CREATE TABLE FIR_T(
Incident_time TIMESTAMP,
Incident_place VARCHAR2(30),
Petitioner_id VARCHAR2(15),
Contact : mrizwan969@gmail.com
Victim_Name VARCHAR2(50),
Victim_Address VARCHAR2(100),
Case_id NUMBER(10,0),
Petitioner_Name VARCHAR2(50),
);
Victim:
CREATE TABLE Victim_T (
Father_name VARCHAR2(50),
Contact NUMBER(12,0),
);
Accused:
CREATE TABLE Accused_T(
Name VARCHAR2(50),
Contact : mrizwan969@gmail.com
Father_name VARCHAR2(50),
NIC VARCHAR2(15),
Photo BLOB,
Finger_Prints BLOB,
FIR_ID NUMBER(5,0),
);
Investigation Officer:
CREATE TABLE Investigation_officer_T(
Name VARCHAR2(50),
Rank VARCHAR2(5),
);
Contact : mrizwan969@gmail.com
Case:
CREATE TABLE Case_T(
Case_Detail LONG,
Section_of_law VARCHAR2(6),
FIR_ID NUMBER(5,0),
Officer_id VARCHAR2(15),
);
• There are two possible values for case_status i.e. either a case is
open or close so only a single character is stored for case status ‘c’ for
closed and ‘o’ for open
Accused Address:
CREATE TABLE Accused_address_T(
);
Contact : mrizwan969@gmail.com
Accused Alias:
CREATE TABLE Accused_alias_T(
);
Accused Contact:
CREATE TABLE Accused_Contact_T(
);
Contact : mrizwan969@gmail.com