IST 220 Introduction to Databases Course Wrap-up.

Slides:



Advertisements
Similar presentations
The Relational Model and Relational Algebra Nothing is so practical as a good theory Kurt Lewin, 1945.
Advertisements

Accounting System Design
Introduction to Structured Query Language (SQL)
Introduction to Databases CIS 5.2. Where would you find info about yourself stored in a computer? College Physician’s office Library Grocery Store Dentist’s.
ASP.NET Database Connectivity I. 2 © UW Business School, University of Washington 2004 Outline Database Concepts SQL ASP.NET Database Connectivity.
Database Design Concepts INFO1408 Term 2 week 1 Data validation and Referential integrity.
Querying a Database Microsoft Office Access 2003.
Introduction to Structured Query Language (SQL)
1 Chapter 2 Reviewing Tables and Queries. 2 Chapter Objectives Identify the steps required to develop an Access application Specify the characteristics.
Database Constraints. Database constraints are restrictions on the contents of the database or on database operations Database constraints provide a way.
Database Architecture The Relational Database Model.
Page 1 ISMT E-120 Introduction to Microsoft Access & Relational Databases The Influence of Software and Hardware Technologies on Business Productivity.
Page 1 ISMT E-120 Desktop Applications for Managers Introduction to Microsoft Access.
1 Microsoft Access 2002 Tutorial 3 – Querying a Database.
© Pearson Education Limited, Chapter 2 The Relational Model Transparencies.
ASP.NET Programming with C# and SQL Server First Edition
PHP Programming with MySQL Slide 8-1 CHAPTER 8 Working with Databases and MySQL.
 SQL stands for Structured Query Language.  SQL lets you access and manipulate databases.  SQL is an ANSI (American National Standards Institute) standard.
Concepts of Database Management, Fifth Edition Chapter 4: The Relational Model 3: Advanced Topics.
Microsoft Access 2003 Define some key Access terminology: Field – A single characteristic or attribute of a person, place, object, event, or idea. Record.
RELATIONSHIPS Generally there are two main database types: flat-file and relational.
Relational Database Management Systems. A set of programs to manage one or more databases Provides means for: Accessing the data Inserting, updating and.
Chapter 7 Working with Databases and MySQL PHP Programming with MySQL 2 nd Edition.
Lecture 7 Integrity & Veracity UFCE8K-15-M: Data Management.
Management Information Systems MS Access MS Access is an application software that facilitates us to create Database Management Systems (DBMS)
Chapter 2 Adapted from Silberschatz, et al. CHECK SLIDE 16.
XP New Perspectives on Microsoft Office Access 2003 Tutorial 9 1 Microsoft Office Access 2003 Tutorial 9 – Using Action Queries, and Defining Table Relationships.
Database: SQL and MySQL
SQL Structured Query Language Programming Course.
1 The Relational Model. 2 Why Study the Relational Model? v Most widely used model. – Vendors: IBM, Informix, Microsoft, Oracle, Sybase, etc. v “Legacy.
Relational Data Model Ch. 7.1 – 7.3 John Ortiz Lecture 3Relational Data Model2 Why Study Relational Model?  Most widely used model.  Vendors: IBM,
MS Access 2007 Management Information Systems 1. Overview 2  What is MS Access?  Access Terminology  Access Window  Database Window  Create New Database.
1 Outline  What is a Primary Key?  AutoNumber primary keys  Single-field primary keys  Composite-field primary key  About Foreign Keys  Database.
Chapter 4Introduction to Oracle9i: SQL1 Chapter 4 Joining Multiple Tables.
Tutorial 9 Using Action Queries and Advanced Table Relationships.
1 © Prentice Hall, 2002 Chapter 5: Logical Database Design and the Relational Model Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B.
Maintaining a Database Access Project 3. 2 What is Database Maintenance ?  Maintaining a database means modifying the data to keep it up-to-date. This.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Chapter 9 Constraints. Chapter Objectives  Explain the purpose of constraints in a table  Distinguish among PRIMARY KEY, FOREIGN KEY, UNIQUE, CHECK,
Chapter 4 Constraints Oracle 10g: SQL. Oracle 10g: SQL 2 Objectives Explain the purpose of constraints in a table Distinguish among PRIMARY KEY, FOREIGN.
Database Fundamental & Design by A.Surasit Samaisut Copyrights : All Rights Reserved.
Chapter 9 Logical Database Design : Mapping ER Model To Tables.
Visual Programing SQL Overview Section 1.
Using SQL Connecting, Retrieving Data, Executing SQL Commands, … Svetlin Nakov Technical Trainer Software University
AL-MAAREFA COLLEGE FOR SCIENCE AND TECHNOLOGY INFO 232: DATABASE SYSTEMS CHAPTER 7 (Part II) INTRODUCTION TO STRUCTURED QUERY LANGUAGE (SQL) Instructor.
IST 318 – DB Administration Data Retrieval Using SELECT statements.
 2001 Prentice Hall, Inc. All rights reserved. 1 Chapter 22 - SQL, MySQL, DBI and ADO Outline 22.1 Introduction 22.2 Relational Database Model 22.3 Relational.
XP New Perspectives on Microsoft Access 2002 Tutorial 31 Microsoft Access 2002 Tutorial 3 – Querying a Database.
Constraints Lesson 8. Skills Matrix Constraints Domain Integrity: A domain refers to a column in a table. Domain integrity includes data types, rules,
Session 1 Module 1: Introduction to Data Integrity
CSCI 3328 Object Oriented Programming in C# Chapter 12: Databases and LINQ – Exercises 1 Xiang Lian The University of Texas Rio Grande Valley Edinburg,
Database: SQL, MySQL, LINQ and Java DB © by Pearson Education, Inc. All Rights Reserved.
Distribution of Marks For Second Semester Internal Sessional Evaluation External Evaluation Assignment /Project QuizzesClass Attendance Mid-Term Test Total.
© 2009 Pearson Education, Inc. Publishing as Prentice Hall 1 Chapter 5 (Part a): Logical Database Design and the Relational Model Modern Database Management.
Chapter 3: Relational Databases
IST 220 – Intro to DB Lecture 4 Database Design thru ER Modeling.
CHAPTER 2 : RELATIONAL DATA MODEL Prepared by : nbs.
1 DBS201: More on SQL Lecture 2. 2 Agenda Select command review How to create a table How to insert data into a table.
7 1 Database Systems: Design, Implementation, & Management, 7 th Edition, Rob & Coronel 7.6 Advanced Select Queries SQL provides useful functions that.
® Microsoft Access 2010 Tutorial 9 Using Action Queries and Advanced Table Relationships.
LM 5 Introduction to SQL MISM 4135 Instructor: Dr. Lei Li.
Constraints Advanced Database Systems Dr. AlaaEddin Almabhouh.
® Microsoft Access 2010 Tutorial 9 Using Action Queries and Advanced Table Relationships.
IT 5433 LM3 Relational Data Model. Learning Objectives: List the 5 properties of relations List the properties of a candidate key, primary key and foreign.
XP Chapter 1 Succeeding in Business with Microsoft Office Access 2003: A Problem-Solving Approach 1 Level 2 Objectives: Understanding and Creating Table.
Data Integrity & Indexes / Session 1/ 1 of 37 Session 1 Module 1: Introduction to Data Integrity Module 2: Introduction to Indexes.
Database Constraints Ashima Wadhwa. Database Constraints Database constraints are restrictions on the contents of the database or on database operations.
Chapter 4 Logical Database Design and the Relational Model
Primary key Introduction Introduction: A primary key, also called a primary keyword, is a key in a relational database that is unique for each record.
CHAPTER 4: LOGICAL DATABASE DESIGN AND THE RELATIONAL MODEL
Presentation transcript:

IST 220 Introduction to Databases Course Wrap-up

Basic Concepts Data Information Database Database management system (DBMS) Relational DB and RDBMS

Database Objects Database objects (as used in MS Access) Tables Queries Select queries Action queries Forms Reports Macros Their purposes

Additional Features (in Access) Views Normal view (datasheet, form, report views) Design view Special views (PivotTable view, SQL view) Controls Bound Unbound Properties (sheet)

Tables Table structure Row (aka as record) Column (aka field, attribute) Identifying: PK Describing Referencing: FK Data types Domain (or value range) Continuous: check (salary >= 0) Discrete: in (‘Y’, ‘N’)

Primary Key A key may consist of one or more attributes Primary key: just one Not null Unique Indexed Candidate key: one or more Unique Not all required (or not null) fields are qualified for a key

Foreign Key Referencing to PK in a related table May not reference any other fields Referential integrity A FK may only accept a value that exists in the corresponding PK Dependence: impacts on the proper order to Create related tables Insert data into these tables Delete data from these tables

Relationships Each table consists of attributes directly related to one subject (to reduce duplication) Relationships are at the heart in joining tables to generate reports Specified through FK-PK links Possible cardinality ratios include One-to-one One-to-many or many-to-one Many-to-many A conjunction table is needed in keeping track of a many- to-many relationship

Joining Tables Equality-joins (btw two directly linked tables) An equality condition is used: FK_value = PK_value Without applying it, leads to all possible combinations (CROSS JOIN) Most of them are invalid Equality-joins (btw two indirectly related tables) Include all tables on the path btw them Applying an equality condition on each PK-FK pair Non-equality joins As btw the book and promotion tables

Basic Operations All DBMS’ support the CRUD operations Read (or select): Won’t change data (as Select Queries in Access) Create (or insert) Update Delete Change data (as Action Queries in Access) Others, such as making a table from a query In Access: Make-Table Queries In SQL: create table t_name as (select …)

Select The syntax SELECT :select column-wise FROM :data source(s) WHERE :select row-wise GROUP BY :partitioning for total queries HAVING :specifying criteria w.r.t. total values ORDER BY :sort in ascending (default) or descending order :it’s possible to sort by multiple fields Up to six clauses Two of them are mandatory Clauses should appear in the order as shown

Create Tables A create table statement defines Names of fields Data types used, with length/precision specs Constraints, defined at Column level Table level Syntax CREATE TABLE t_name ( Field_name type ( length ) in-line_constraint_def, CONSTRAINT c_name c_type ( field(s) ) constraint_def );

Insert The syntax INSERT INTO t_name ( field(s) ) :optional VALUES ( value(s) :one for each field listed above ) :or as exists in the table if not specified Examples

Update The syntax UPDATE t_name SET :only one SET keyword is needed field = value [, field = value, …] WHERE condition(s) :usually needed Examples

Delete The syntax DELETE [FROM] t_name :the FROM keyword may be omitted WHERE condition(s) :usually needed Although DELETE [FROM] t_name will remove all records in the table, the table still exists To remove the table definition, user DROP TABLE statement Examples

Macros Objects that can help automate your Access application Design view Action Comments Optionally named May be invoked by clicking a button or when the system starts up A normal form A switchboard form