Managing Data

You might also like

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 44

ISMT 101

Managing Data
Business implications
Mgmt

Organizational use
Major IS (1) (1) Digital EB
Economy (7)

1. Why database mgmt


People -- Files do not work
Technology components
2. Functions of DB
3. Models of DB
-- “Bagel test”
HW SW Network Internet DB 4. Data security
(2) (3) (5) (6) (4) -- Encryption
Why DB management

Store
Employees
 Store data in different functional areas
Store
Managers
 Data exchange between functional areas
HK Regional
Managers  Data processing, to generate useful info

Headquarter  Info exchange along administrative level

Finance/ Human
Operations Marketing
Accounting Resources
Basic concepts in data mgmt

 Bits  Characters (letters, numbers, symbols)


 E.g., “a” = 10001101
 Field
 Made up of one or more bytes, or characters
 Field—individual piece of data
 Examples: name, address, phone number

 Record
 Fields
that are grouped together for a specific purpose
 Example: students’ records on the instructor’s computer
Basic concepts in data mgmt

 Primary key
 A field, or group of fields, that uniquely identifies
an individual record
 E.g., student id number for records describing
students
 E.g., {who sells which product to whom} describing
transaction, or using an transaction ID
Basic concepts in data mgmt

 A table/file combines logically related records.


 E.g., records of all students in ISMT 101.
 E.g., all patients’ records in a department at a hospital.
 Logically related tables form a database.
 E.g., a university database includes
 a student records table
 an employee records table
 a course listing table
Primary
Key

Table
How to manage data

 You may use file systems, instead of DB


 Anomalies (errors), redundancy
 Stores together groups of records together
used by a particular software application
 e.g., store information in Excel spreadsheet
 e.g., use a table in MS Word to store info
 One of the simplest ways to store data
File systems – drawback

 Inability to share data


 E.g.,in a university, student accounts office used a
complex Word table, registrar's office used Excel
spreadsheet
 Student paid tuition  update Word table  email 
data re-entry into spreadsheet, inefficient
 Inadequate security
 Some file may require password to access, some
may not
 There is a lack of unified security control
File systems – drawback

 Allows data duplication (e.g. redundancy)


 Bob left his info at the registrar’s and account office
twice  cause data redundancy
 Data redundancy: same data are stored at
different places.
 Usually caused by the use of file systems.
 More seriously, errors (anomalies) may occur!
File systems – Anomalies

 Insertion anomaly
 Data need to be entered more than once when
the data are located in multiple file systems
 People may make mistakes in data re-entry
 E.g., Tom’s address is put in two files twice
File systems – Anomalies

 Modification anomaly
 Redundant data in separate file systems
becomes inconsistent
 E.g., Tom changed his address in the
registrar’s office, but forgot to change in
account office.
File systems – Anomalies

 Deletion anomaly
 Failure
to simultaneously delete all copies of
redundant data
 E.g.,Tom graduated. He notified the
registrar’s office but not the account office.
A business case study

 Until 2005, Ferrari still used


spreadsheets to manage customer data
 Wide Internet presence (advertisement,
membership support, marketing campaign…)
 Information from each website  spreadsheet
 No centralized means of tracking memberships

 Solution in 2006 – provided by PeopleSoft


 CentralizedOracle data base
 Data sharing over the Internet
DBMS

 Database management system (DBMS)—


software that creates and manipulates
data
 Companies used Oracle's Database, IBM’s DB2…
 You used Access
DBMS function
DBMS stores data physically
 Manage stored data
 Transform the way
data is physically
stored into whatever
logical view of the
data that users
choose
 Hides the physical
details of how the data
is stored Users focus on own logic views
DBMS function
DBMS stores data physically
 Physical view – the
approach DBMS
stores data

 Logical view – the


way users retrieve
fields and records
across tables
Users focus on own logic views
DBMS function

 Provide security
 DBMS controls who
can add, view,
change, or delete
data in the database
 Allow multi-user access
 Controls concurrency
of access to data
DBMS function – manage concurrency

1
DBMS only
allows Mary to
work on the
2 price database.
There is a short
Before Mary is time window for
done, Bob Mary, e.g., 2
cannot access minutes.
the database.
Database Models

 Four common database models


 Flat file model – the simplest
 Hierarchical model – small-scale database
 Network model – rarely used
 Relational model – most widely used
Flat file model
Flat file model stores data in a basic table structure,
much like a spreadsheet
Hierarchical model
 Its structure looks like an inverted tree,
tree with the root
at the top
 When you look for info, you start from the top
 Limited to storing data in one-to-many relationships

ISMT101

6 sections

Many students
Hierarchical model

 Very fast when searching large amounts of data


in a pre-specified order
 Inother words, this model mainly supports structured
searching
 Not very flexible
 Support one-to-many relationships
 E.g., students can participate in many associations
Network model
 Any record may be linked to any other record
 Highly flexible but also highly complex
 Rarely used
Relational model
 Flexible and relatively simple to use
 Somewhat slower than hierarchical and network
models
 Uses managed redundancy to create fields that
provide linkage between tables
 These fields are called foreign keys – the secret to a
relational database
 A foreign key is a field, or group of fields, in one table
that is the primary key of another table
Managed data redundancy can link table to each other.

Unique
feature:
The ability
to relate
tables
Bagel test

 “Freakonomics”
 Paul, trained as an economist, analyzed weapons
expenditure for the US Navy, in Washington DC.

 In 1984, he became “the guy who brings the bagels.”


 Every morning, he would deliver some bagels and a
cash basket to a company’s snack room.

 He would return before lunch to pick up the money.


 This is an honor-system. No monitoring.
Bagel test

 Paul considered the following questions?

 Did they steal from me?


 If so, what were the characteristics of a company that
stole?
 In what situations did people tent to steal more, or
less?
A file system

Enron
100, $40
HKUST
IBM
50
100
$50
$98

IBM
100
$95
Enron
98, $45
Creating a DB
Step One: Develop a clear understanding of
the process of the business

 One customer (company) may order many


transactions, but one specific transaction
applies to exactly one customer.

 One transaction may include many bagel


names (brands), and one bagel name may be
included in many different transactions.
Creating a DB
One  Many Many  Many

Customer Transaction Bagel


Creating a DB
Step two: Develop a conceptual model –

 Draw an Entity-Relationship (ER) diagram


to represent the conceptual model
 You can use DBMS to draw ER-diagram
Relationships:
One, Many

Entity: fields, key


Creating a DB
Step three: convert ER-diagram to a relational
database.
DBMS can automatically finish the conversion.
Bagel test

 Smaller offices are more honest than


big ones
 Unseasonable raining makes people
cheat
 An office is more honest when
employees like their boss.
……
Managing data security—

Public/private key encryption


Security is a critical concern in e-business
Reduce payment
fraud in e-business

Correct Right Genuine No Honest


data user card misuse people

Verified-by- Internal Education,


Encryption CVV2
Visa Mgmt Police…

IT management General mgmt


Without encryption

“Alice, I want to
tell u sth…it’s
between us”

“OK…Bob…u
can post it on
the Big-Character-Word-Wall
@ UST”

??? Just like posting information


on Web without encryption
Public/private key encryption

“Alice, I want to
tell u sth…it’s
between us”
“OK…Bob…u
Write me a letter.
My address is
P.O. Box 1301” Rent a PO
mailbox
Send a letter to Get the letter
this public address using her
private key
Public/private key encryption
Big random Alice’s
number Key-making private key
K4D94KJ
algorithm
JD325K4 Alice’s
public key

“Hello Bob has the


Encrypt
Alice!” public key
(via the Internet
or through
6D3N0DS23N… third party)

“Hello Alice’s
Decrypt private key
Alice!”
Critical factors in private/public key encryption

 One-to-one match
 A public key is uniquely matched to a private key.
 Anyone can encrypt using the public key, but only the
holder of the private key can decrypt.
 Guaranteed by the mathematical algorithm
 Secrecy depends on the secrecy of the private key.
Take-Away
 DB helps reduce data redundancy and
I/M/D anomalies.

 ER-diagram  relational DB

 Public/private key encryption

You might also like