CS 3630 Database Design and Implementation. Assignment 3 Style! Agreement between database designer and the client. UserName1_EasyDrive UserName2_EasyDrive.

Slides:



Advertisements
Similar presentations
Copyright © 2003 Pearson Education, Inc. Slide 8-1 The Web Wizards Guide to PHP by David Lash.
Advertisements

Announcements Read 6.4 – 6.6 for Monday Homework 5, due Friday (today) Project Step 4, due Monday Research paper –List of sources - due 10/29.
Session 2Introduction to Database Technology Data Types and Table Creation.
CS 3630 Database Design and Implementation. SQL Query Clause Select and From Select * From booking; select hotel_no, guest_no, room_no from booking; select.
Let’s try Oracle. Accessing Oracle The Oracle system, like the SQL Server system, is client / server. For SQL Server, –the client is the Query Analyser.
Quick-and-dirty.  Commands end in a semi-colon ◦ If you forget, another prompt line shows up  Either continue the command or…  End it with a semi-colon.
1 A GUIDE TO ORACLE8 CHAPTER 2: Creating and ModifyingDatabaseTables 2.
Fundamentals, Design, and Implementation, 9/e COS 346 Day 11.
1 Chapter 2: Creating and Modifying Database Tables.
Fundamentals, Design, and Implementation, 9/e Chapter 6 Introduction to Structured Query Language (SQL)
A Guide to SQL, Seventh Edition. Objectives Understand the concepts and terminology associated with relational databases Create and run SQL commands in.
Murali Mani SQL DDL and Oracle utilities. Murali Mani Datatypes in SQL INT (or) INTEGER FLOAT (or) REAL DECIMAL (n, m) CHAR (n) VARCHAR (n) DATE, TIME.
DT211 Stage 2 Databases Lab 1. Get to know SQL Server SQL server has 2 parts: –A client, running on your machine, in the lab. You access the database.
SQL Keys and Constraints Justin Maksim. Key Declaration Key constraint defined within the CREATE TABLE command Key can be declared using either the PRIMARY.
7/2/2015Murali Mani -- CS5421 Database Management Systems DB Application Development Project Statement + Introduction to Oracle.
A Guide to MySQL 3. 2 Objectives Start MySQL and learn how to use the MySQL Reference Manual Create a database Change (activate) a database Create tables.
Oracle SQL*plus John Ortiz. Lecture 10SQL: Overview2 Overview  SQL: Structured Query Language, pronounced S. Q. L. or sequel.  A standard language for.
Your Oracle Account UserName is the same as your UWP username Followed Not case sensitive Initial Password: UWPstudent Password is case sensitive.
A Guide to SQL, Eighth Edition Chapter Three Creating Tables.
Session 5: Working with MySQL iNET Academy Open Source Web Development.
1 An Introduction to SQL. 2 Objectives  Understand the concepts and terminology associated with relational databases  Create and run SQL commands 
 SQL stands for Structured Query Language.  SQL lets you access and manipulate databases.  SQL is an ANSI (American National Standards Institute) standard.
CS450 HW2Page 1 Homework #2  Due the midnight of April 15th.  100 Points  In this homework, you create an SQL script to build the MOVIES database according.
Chapter 7 Working with Databases and MySQL PHP Programming with MySQL 2 nd Edition.
CS 3630 Database Design and Implementation. Your Oracle Account UserName is the same as your UWP username Followed Not case sensitive Initial.
CHAPTER:14 Simple Queries in SQL Prepared By Prepared By : VINAY ALEXANDER ( विनय अलेक्सजेंड़र ) PGT(CS),KV JHAGRAKHAND.
Web Scripting [PHP] CIS166AE Wednesdays 6:00pm – 9:50pm Rob Loy.
CSC 2720 Building Web Applications Database and SQL.
Database control Introduction. The Database control is a tool that used by the database administrator to control the database. To enter to Database control.
1 Structured Query Language (SQL). 2 Contents SQL – I SQL – II SQL – III SQL – IV.
1 Creating and Modifying Database Objects. 2 An Oracle database consists of multiple user accounts Each user account owns database objects Tables Views.
Web Scripting [PHP] CIS166AE Wednesdays 6:00pm – 9:50pm Rob Loy.
SQL Basics. 5/27/2016Chapter 32 of 19 Naming SQL commands are NOT case sensitive SQL commands are NOT case sensitive But user identifier names ARE case.
Chapter 5 MYSQL Database. Introduction to MYSQL MySQL is the world's most popular open-source database. Open source means that the source code, the programming.
Oracle 11g DATABASE DEVELOPMENT LAB1. Introduction  Oracle 11g Database:-  Oracle 11g database is designed for some features, which helps to the organizations.
Database Processing: Fundamentals, Design, and Implementation, 9/e by David M. KroenkeChapter 6/1 Copyright © 2004 Please……. No Food Or Drink in the class.
Intro to SQL| MIS 2502  Spacing not relevant › BUT… no spaces in an attribute name or table name  Oracle commands keywords, table names, and attribute.
Personal Oracle8i Create a new user Create a new table Enter data into a new table Export & import data Start and exit SQL Plus SQL Plus Syntax.
Creating Tables and Inserting Records -- Not easy to edit! -- check constraints! Create table test1 ( C1 char(5) primary key, C2 Varchar2(15) not null.
ITBIS373 Database Development Lecture 3a - Chapter 3: Using SQL Queries to Insert, Update, Delete, and View Data.
A Guide to MySQL 3. 2 Introduction  Structured Query Language (SQL): Popular and widely used language for retrieving and manipulating database data Developed.
SQL Fundamentals  SQL: Structured Query Language is a simple and powerful language used to create, access, and manipulate data and structure in the database.
CS 3630 Database Design and Implementation. Database Schema Branch (Bno…) Staff (Sno…Bno) Owner (Ono…) PropertyForRent (Pno…Ono) Renter (Rno…) Viewing.
Prince Sultan University Dept. of Computer & Information Sciences CS 340 Introduction to Database Systems.
1 Chapter 2: Creating and Modifying Database Objects.
Agenda for Class 2/02/2006 Finish discussing constraints generated with the CREATE TABLE statement. Discuss DROP statement. Discuss INSERT, COMMIT, DELETE,
ITEC 3220A Using and Designing Database Systems Instructor: Prof. Z. Yang Course Website: 3220a.htm
>> Introduction to MySQL. Introduction Structured Query Language (SQL) – Standard Database Language – Manage Data in a DBMS (Database Management System)
Oracle 9i. Agenda Start and exit SQL Plus (General) Start and exit SQL Plus (Tah 1006) Syntax Create a new user Create a new table Enter data into a new.
Agenda for Class 2/20/2014 Introduce Microsoft’s SQL Server database management system. Use the lab to discuss how to CREATE, DROP and populate (INSERT)
Starting with Oracle SQL Plus. Today in the lab… Connect to SQL Plus – your schema. Set up two tables. Find the tables in the catalog. Insert four rows.
1 Introduction to SQL *Plus Oracle SQL Interface MIS309 Database Systems.
Basic SQL*Plus edit and execute commands SQL*Plus buffer and built-in editor holds the last SQL statement Statements are created in free-flow style and.
CS320 Web and Internet Programming SQL and MySQL Chengyu Sun California State University, Los Angeles.
SQL Tutorial CPSC 608 Database System. Connecting to Oracle Your username is identical to your UNIX account To access your Oracle account, you need to.
Dept. of Computer & Information Sciences
3 A Guide to MySQL.
CS 3630 Database Design and Implementation
CS 3630 Database Design and Implementation
CS320 Web and Internet Programming SQL and MySQL
CS 3630 Database Design and Implementation
CS 3630 Database Design and Implementation
CS 3630 Database Design and Implementation
SQL in Oracle.
ORACLE SQL Developer & SQLPLUS Statements
CS 3630 Database Design and Implementation
CS 3630 Database Design and Implementation
CS3220 Web and Internet Programming SQL and MySQL
CS3220 Web and Internet Programming SQL and MySQL
Presentation transcript:

CS 3630 Database Design and Implementation

Assignment 3 Style! Agreement between database designer and the client. UserName1_EasyDrive UserName2_EasyDrive 2

Project Phase I 20 Points Could lose up to 10 points! 3

Project Phase I 20 Points Due Monday, March 30 Sign up for groups by 4 pm, March 23 (-2 for each late day) Members may not receive the same grade! Report any issues to me. 4

Test 1 5

Assignment7 Create tables with constraints 6

Your Oracle Account Using EDDB_SQL+ (not SQL PLUS) UserName is the same as your UWP username Followed Not case sensitive Initial Password: UWPUserName1 (all lower case) Example: yangq1 Password is case sensitive 7

Reset Your Oracle Password Must reset password after login the first time If you forget your password – to HelpDesk at from your UWP account –cc to Kenneth M Wiegman (He will do it) –cc to Qi Yang (I cannot do it) 8

Assignment7 Create tables with constraints Using Script File (Program) Style: could lose five points! 9

UserName_Lab7.sql Name : Qi Yang -- UserName : YangQ -- Date : Course : CS Description: Drop tables -- Create tables -- Insert records Drop Table test2; Drop Table test1; Create table test1... Desc Test1 Pause Create Table Test2... Desc test2 Pause Insert into test1... Commit; Select * From Test1;... 10

SQL Script File Using any text editor outside SQL*Plus File extension.SQL UserName_Lab7.Sql Multiple SQL commands Each command ends with ; 11

Running Script File Using either Start SQL> Start file_name_with_full_path Use Arrow Keys to get previous commands! 12

Create a Table Create Table Test1 ( C1 Char(5) Primary Key, C2 Varchar2(50), C3 Integer, C4 Date); 13

Create another Table Create Table Test1 ( C1 Char(5) Primary Key, C2 Varchar2(50), C3 Integer, C4 Date); Create Table Test2 ( D1 VARCHAR2(15) Primary Key, D2 Char(5) references Test1, D3 Integer); 14

Drop Tables Drop table test1; Drop table test2; Create Table Test1 ( C1 Char(5) Primary Key, C2 Varchar2(50), C3 Integer, C4 Date); Create Table Test2 ( D1 VARCHAR2(15) Primary Key, D2 Char(5) references Test1, D3 Integer); 15

Drop Tables Drop table test2; Drop table test1; Create Table Test1 ( C1 Char(5) Primary Key, C2 Varchar2(50), C3 Integer, C4 Date); Create Table Test2 ( D1 VARCHAR2(15) Primary Key, D2 Char(5) references Test1, D3 Integer); 16

Insert Records Insert into Test1 Values ('cs363', 's1', 44, '28-feb-12'); Insert into Test1 Values ('cs334', 's2', 45, '29-feb-12'); One record at a time! Single quotes for string Date is entered as string in the default format 17

Insert Records Insert into Test2 Values ('Database', 'cs363', 44); Insert into Test2 Values ('Windows', Null, 54); Insert into Test2 Values ('OOP I', 'cs243', 60); Insert into Test2 Values ('OOP I', 'cs363', 60); Insert into Test2 Values ('OOP II', 'cs243', 100); 18

Retrieve Records Select * From Test1; Pause Select * From Test2; 19

Assignment7 Table names and column names must be exactly the same as specified. 20