Download Tucker_Intro

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Oracle Database wikipedia , lookup

Entity–attribute–value model wikipedia , lookup

Open Database Connectivity wikipedia , lookup

IMDb wikipedia , lookup

Extensible Storage Engine wikipedia , lookup

Microsoft Jet Database Engine wikipedia , lookup

Concurrency control wikipedia , lookup

Relational model wikipedia , lookup

Database wikipedia , lookup

ContactPoint wikipedia , lookup

Clusterpoint wikipedia , lookup

Database model wikipedia , lookup

Transcript
CS 474 Database Design and
Application
Terminology
Jan 11, 2000
Administrivia
 Show
of hands - who has not had CS239 or
ISAT 340 or CS274.
Database
 Database
- Collection of related data with
implicit meaning.
• Your cards are a database.
• The phone book is a database.
• Your filing systems are databases.
Data
 Data
- Known facts that can be recorded
and have meaning.
• Your cards are the database and what you have
recorded (written) on them is the data.
• The entries in the phone book are data.
• The information written in your file system is
data.
Databases, cont
 Collection
of related records with specific
meanings
•
•
•
•
•
Random assortment of data is not a database.
Designed for a specific purpose.
Have a source for the data.
Have a specific audience who will use the data.
Represents some aspect of the real world.
– models real world entities and real world processes.
Database Management System
 Abbreviated
DBMS.
 Collection of programs to enable users to
build and maintain databases.
 General purpose software, like a
programming language.
Database Management Systems,
cont
 Your
book talks about a database system as
being a “computerized record-keeping
system”. Databases do not need to be on
computers, but they do keep records.
 Our focus in class will be (of course) the
computerized database system.
What makes up a database?
 Database
- central file store.
 File - a collection of individual records.
 Record - is a collection of data elements
about one entity.
 Data element - a single piece of data with
properties.
Operations on Databases
 Creation
and removal of files
 Insertion and deletion of individual records
within files.
 Changing data within existing files.
 Retrieving data from existing files.
Database system components
 Data
 Hardware
on which it resides
 Software that manipulates the data
 Users that maintain or use the data
Data
 In
a database, data are organized in such a
way that we can make efficient use of the
data. (Files in a cabinet are organized to
make insertion, deletion, and retrieval
easier).
 The book talks about integretation of data
and sharing.
Integration
 Separate
diverse data (files) are organized in
such a way that we can make use of
disparate data across the system. For
example, if I am in the Admissions office
and I want to know which of my recruits
from last year are still in school, I would
access the Registration information.
Integration leads to efficiency of operations.
Integration
 Also
means that we can reduce the
redundancy of the data. If both the
Admissions office and the Registrar’s office
need names of students, we can store the
names in one file and both offices can use
those names with their individual files.
Redundancy
 This
property allows us to control the
redundancy in the system, by allowing us to
put common data in one place which is
accessible from everywhere in the system.
 Redundancy - duplication of data across
systems.
Why is redundancy bad?
 Loss
of efficiency - as each office is
collecting data, each person is spending
time gathering data that the organization
already has in hand.
 Inconsistency - a change in data in one
place is not necessarily propogated to all
offices.
 Storage is wasted - extra space to house the
duplicate information.
Shared data
 By
integrating the database, you permit
your users to share data across offices.
 That enables queries, research and
processes to use the entire collection of
data.
Is all data shared?
 Typically,
no.
 Each user will have his/her own view of the
data. That view will be customized to their
needs.
 Some data should not be viewed by all
users. Protections (security) prevent
unauthorized access to data.
Hardware
 Hardware
provides the “file cabinet” for the
database. It provides a place on which the
data resides.
 Hardware also provides us with some tools
to maintain the data (keyboard, tapes,
modem, memory).
Software - DBMS
 The
Database Management System
(DBMS) provides a layer between the
stored data and the users.
 All requests for manipulation of data go
through the DBMS.
Services typically provided
 Design
the database. Includes ability to
build new files, remove files, add elements
to files, establish the “connections” between
files.
 Manipulate the database. Includes features
that enable users to directly access the data
housed in the database. Provides change,
retrieval, insertion, and deletion functions.
Services provided, cont.
 DBMS
typically provide a way to protect
the data from unauthorized use.
Identification of users and password
protection of the database level.
 DBMS typically provide a way to
customize users views of the database
(which is also a protection).
Examples of DBMS systems
 MS Access
 Oracle
 MS
SQL Server
 Dbase
Each product from each vendor will have
some of its own unique features.
Users
 Users
provide the fourth component of the
system.
 Users interpret the data found in the dbms.
 Users maintain the database and data within
the data base.
User “classes”
 Application
 End
programmers
users
 Database Administrators
Application programmers
 Make
use of the database in their programs.
 They may issue queries, provide screens,
provide reports, provide other processing to
the users of the system.
 Build “user” interfaces into the application.
 Database provides “data independence”
with their applications. (Database can
change, while applications remain
constant).
End Users
 Typically
use the database through some
user interface functions provided by the
application programmers.
 May use functions provided directly by the
database management system, such as
queries.
Database Administrator
 Maintains
the database itself.
 Usually maintains the security within the
system.
 May not decide what the security schema is.
 May not decide what is needed in the
database.
Databases, cont
 Book
talks about “persistent” data.
Typically a database is developed to retain
data over time.
 Some of that data will have a longer life
than other data. Some data will “persist”
for only a few moments to support some
other type of processing.
Data as an Organizational Asset
 We
spend time on databases since data is
one of the most valuable assets within an
organization.
 We spend time collecting it; we spend time
retrieving it.
 A good database design facilitates the use of
that organizational asset. A bad database
design will devalue the asset.
Advantages of a database
 Data
independence - separate the
application from the details of the
underlying data. Applications interact with
the DBMS not with the actual data.
 Database applications provide transaction
support. A transaction (or logical unit of
work) either goes all the way through or
goes none of the way. It cannot be divided.
How do we represent that data?
Entities and Relationships

An entity is any object about which we want to
gather information.
•
•
•
•

Students
Courses
Grades
Professors
A relationship describes how those entities are
connected to one another. (A relationship might be
an entity in its own right.)
E/R Diagram
 Provides
the “picture” of the database using
entities and the relationships among those
entities.
 Take a look at page 11 of the book.
 We will spend more time on this shortly.
Entities, cont
Entities have properties which describe that entity.
 Your cards have listed some properties of the
students that you interviewed.
 Each type of entity will have its own unique
properties and often some properties that it shares
with other entities.

• Ex. Cars and trucks might be two entities, but they
share many properties such as having wheels.
What is a relational database
 Any
database that is based on the formal
theory called “The relational model of
data.”
 Consists of “tables” which are equivalent to
files.
 Consists of “rows” and “columns”.
 Consists of formal operations to work with
the tables.
What are some other types?
Hierarchical database system - Data is represented
as a tree structure with pointers from one entity to
another.
 Netword database system - Data is represented as
a network of entities.
 The database system is categorized by its data
structure.
 We will only be dealing with relational databases.

Conclusion
 Next
time - read chapter 2. We will start on
3 by the end of next week.
 Be able to answer exercises 1 - 5 in Chap 1.