Database - Chapter8 DatabaseandSQL Objective Whatdatabaseis

Info iconThis preview shows pages 1–13. Sign up to view the full content.

View Full Document Right Arrow Icon
Chapter 8 Database and SQL
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
What database is What is relational database What are the types of relationships How to create relationships among entities How SQL is used to retrieve and sort  records from a database Objective
Background image of page 2
 A collection of data about a topic or topics of  interest.   Objective   Data In -- Information Out  Database But Remember Garbage In -- Garbage Out! So, be careful as you work with data!
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
A D atab ase M anagement S ystem (DBMS) is a software program that is used  to manage data in a database: add, change, delete retrieve sort report form archive DBMS
Background image of page 4
 A relational database is one in which data entities are related to each other.  A database file  or table or entity columns  or  fields  or  attributes rows   or   records  Files (tables) are managed by a DBMS Relational Database Student_I D Student_FNa me Student_LNa me Student_Pho ne G0026598 Fred Smith 703 336 6589 G0365982 Anne Ebby 703 695 5879 G0369865 Mike Watson 541 899 4569 Primary Key
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
 Student    Class  Professor    Major   Advisor In a database for a university, the entities might be -  Entity
Background image of page 6
Class Professor  Entities are linked by  relationships     Relationship is a common item  (field) between the tables.  The relationship between any  two entities can be Quantified:  1:Many Many:1 Many:Many 1 Many   One (1)  professor teaches  many  classes. Relationship quantification is called  Cardinality. Relationships
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
1:M Each manager has many employees Relationship between Manager  and Employees
Background image of page 8
Class Student Many          Many Psych 100 Paint 318 Econ 207 Each  student  may register in several  classes  & each  class  enrolls many  students . Relationships between Students and  Classes
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Map of the database Schema Student Class Advisor Major Professor Many One Legend: One Many
Background image of page 10
Data Redundancy Prof_ID Prof_FName Prof_LName Prof_Phone Course_ID Course_Title G0236958 Amy Gordon 202 236 6598 IT 103 Intro. to Computing G0236958 Amy Gordon 202 236 6598 IT 213 Computer Graphics G0989782 Bill Lyons 703 236 2356 IT 331 Web Development G0236958 Amy Gordon 202 236 6598 IT  223 Computer Security A database file could have records for all students and  their courses.  Putting all data in one file can be inefficient! Can you spot the data redundancy ?
Background image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
wasted disk space slower processing data inconsistency ?
Background image of page 12
Image of page 13
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/06/2011 for the course IT 103 taught by Professor Sangjara during the Fall '08 term at George Mason.

Page1 / 43

Database - Chapter8 DatabaseandSQL Objective Whatdatabaseis

This preview shows document pages 1 - 13. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online