8 Copyright © 2004, Oracle. All rights reserved. Managing Schema Objects.

Slides:



Advertisements
Similar presentations
11 Copyright © Oracle Corporation, All rights reserved. Managing Tables.
Advertisements

9 Copyright © 2004, Oracle. All rights reserved. Using DDL Statements to Create and Manage Tables.
9 Creating and Managing Tables. Objectives After completing this lesson, you should be able to do the following: Describe the main database objects Create.
Data Definition Language (DDL)
5 Copyright © 2005, Oracle. All rights reserved. Managing Database Storage Structures.
Copyright  Oracle Corporation, All rights reserved. 10 Creating and Managing Tables.
Database Basics I101 Summer 2006 Copyright 2004, Matt Hottell.
9 Copyright © Oracle Corporation, All rights reserved. Creating and Managing Tables.
Representing Data Elements Gayatri Gopalakrishnan.
1 A GUIDE TO ORACLE8 CHAPTER 2: Creating and ModifyingDatabaseTables 2.
1 Chapter 2: Creating and Modifying Database Tables.
Managing Schema Objects
Database Modifications A modification command does not return a result as a query does, but it changes the database in some way. There are three kinds.
Copyright ©2014 Pearson Education, Inc. Chapter 6 Physical Design Chapter6.1.
Oracle Data Definition Language (DDL)
Overview of SQL Server Alka Arora.
Oracle for Software Developers. What is a relational database? Data is represented as a set of two- dimensional tables. (rows and columns) One or more.
Oracle Database Architecture An Oracle server: –Is a database management system that provides an open, comprehensive, integrated approach to information.
Chapter 6 Additional Database Objects
9 Copyright © 2005, Oracle. All rights reserved. Administering User Security.
CS 3630 Database Design and Implementation. Your Oracle Account UserName is the same as your UWP username Followed Not case sensitive Initial.
Daybase (DayCart) Introduction What is ‘Daybase’ ? Oracle Schema Objects. Oracle Datatypes. Simple Example. Demo.
Oracle Data Definition Language (DDL) Dr. Bernard Chen Ph.D. University of Central Arkansas Fall 2008.
Oracle Database Administration
7 Copyright © 2004, Oracle. All rights reserved. Administering Users.
10 Copyright © 2009, Oracle. All rights reserved. Using DDL Statements to Create and Manage Tables.
1 Copyright © 2006, Oracle. All rights reserved. Using DDL Statements to Create and Manage Tables.
Copyright © 2004, Oracle. All rights reserved. Using DDL Statements to Create and Manage Tables.
Sizing Basics  Why Size?  When to size  Sizing issues:  Bits and Bytes  Blocks (aka pages) of Data  Different Data types  Row Size  Table Sizing.
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.
11 3 / 12 CHAPTER Databases MIS105 Lec15 Irfan Ahmed Ilyas.
10 Creating and Managing Tables Objectives At the end of this lesson, you will be able to: Describe the main database objects Create tables Describe.
10-1 Copyright  Oracle Corporation, All rights reserved. Database Objects ObjectDescription TableBasic unit of storage; composed of rows and columns.
9 Copyright © Oracle Corporation, All rights reserved. Creating and Managing Tables.
Copyright  Oracle Corporation, All rights reserved. 10 Creating and Managing Tables.
Oracle9i Database Administrator: Implementation and Administration 1 Chapter 14 Globalization Support in the Database.
SQL Fundamentals  SQL: Structured Query Language is a simple and powerful language used to create, access, and manipulate data and structure in the database.
9 Copyright © 2004, Oracle. All rights reserved. Using DDL Statements to Create and Manage Schema Objects.
6 Copyright © 2005, Oracle. All rights reserved. Managing Schema Objects.
8 Copyright © 2007, Oracle. All rights reserved. Managing Schema Objects.
Week 7 Lecture 2 Globalization Support in the Database.
SQL ORACLE 1. Data Type 2 3 VARCHAR2(size [BYTE | CHAR]) Variable-length character string having maximum length size bytes or characters. Maximum size.
Data types  CHAR (size): This data type is used to store character strings values of fixed length. The size in brackets determines the number of characters.
9 Copyright © Oracle Corporation, All rights reserved. Creating and Managing Tables.
SQL CREATING AND MANAGING TABLES lecture4 1. Database Objects ObjectDescription TableBasic unit of storage; composed of rows and columns ViewLogically.
6 Copyright © 2007, Oracle. All rights reserved. Managing Database Storage Structures.
1 Chapter 2: Creating and Modifying Database Objects.
Sql DDL queries CS 260 Database Systems.
Creating and Managing Tables 14. ObjectivesObjectives After completing this lesson, you should be able to do the following: After completing this lesson,
Academic Year 2015 Autumn. MODULE CC2006NI: Data Modelling and Database Systems Academic Year 2015 Autumn.
Declaring PL/SQL Variables
Lecture # 24 Introduction to SQL Muhammad Emran Database Systems.
8 Copyright © 2005, Oracle. All rights reserved. Managing Schema Objects.
11 Copyright © 2004, Oracle. All rights reserved. Performing a Migration Using Oracle Migration Workbench (Part II)
Creating and Managing Tables. Database Objects ObjectDescription TableBasic unit of storage; composed of rows and columns ViewLogically represents subsets.
7 Copyright © 2004, Oracle. All rights reserved. Managing Schema Objects.
Relational Databases and SQL The relational model and the most common SQL commands.
15 Copyright © Oracle Corporation, All rights reserved. Managing Users.
Introduction To Oracle
CS 3630 Database Design and Implementation
Data Definition and Data Types
DATABASE SQL= Structure Query Language مبادئ قواعد بيانات
Managing Objects with Data Dictionary Views
SQL data definition using Oracle
ORACLE I 2 Salim Phone : YM : talim_bansal.
PT2520 Unit 5: Physical Design
Managing Tables.
Introduction to Oracle
Presentation transcript:

8 Copyright © 2004, Oracle. All rights reserved. Managing Schema Objects

8-2 Copyright © 2004, Oracle. All rights reserved. Objectives After completing this lesson, you should be able to do the following: Create and modify tables Define constraints View the attributes of a table View the contents of a table Create indexes and views

8-3 Copyright © 2004, Oracle. All rights reserved. What Is a Schema? HR schema HR user owns

8-4 Copyright © 2004, Oracle. All rights reserved. Schemas Schemas created as part of the database creation process: SYS SYSTEM Sample schemas

8-5 Copyright © 2004, Oracle. All rights reserved. Schemas - Full Notes Page

8-6 Copyright © 2004, Oracle. All rights reserved. Accessing Schema Objects Click a link to access the schema objects.

8-7 Copyright © 2004, Oracle. All rights reserved. Naming Database Objects Names must be from 1 to 30 bytes long with these exceptions: –Names of databases are limited to 8 bytes –Names of database links can be as long as 128 bytes Nonquoted names cannot be Oracle reserved words. Nonquoted names must begin with an alphabetic character from your database character set.

8-8 Copyright © 2004, Oracle. All rights reserved. Naming Database Objects Nonquoted names can contain only –Alphanumeric characters from your database character set –The underscore (_) –Dollar sign ($) –Pound sign (#) No two objects can have the same name within the same namespace

8-9 Copyright © 2004, Oracle. All rights reserved. Schema Object Namespaces The following have their own namespace: Indexes Constraints Clusters Database triggers Private database links Dimensions The following are in the same namespace: Tables Views Sequences Private synonyms Stand-alone procedures Stand-alone stored functions Packages Materialized views User-defined types

8-10 Copyright © 2004, Oracle. All rights reserved. Specifying Data Types in Tables Common data types: CHAR(size) : Fixed-length character data of length size bytes VARCHAR2(size) : Variable-length character string having maximum length size bytes DATE : Valid date range from January 1, 4712 BC to December 31, 9999 AD NUMBER(p,s) : Number having precision p and scale s

8-11 Copyright © 2004, Oracle. All rights reserved. Other Data Types FLOAT INTEGER NCHAR NVARCHAR2 LONG LONG RAW RAW ROWID UROWID BLOB CLOB NCLOB BFILE TIMESTAMP

8-12 Copyright © 2004, Oracle. All rights reserved. Other Data Types Full Notes Page

8-13 Copyright © 2004, Oracle. All rights reserved. Creating and Modifying Tables Specify the table name and schema. Specify the column names, data types, and lengths.

8-14 Copyright © 2004, Oracle. All rights reserved. Creating and Modifying Tables Full Notes Page

8-15 Copyright © 2004, Oracle. All rights reserved. Understanding Data Integrity

8-16 Copyright © 2004, Oracle. All rights reserved. Understanding Data Integrity Full Notes Page

8-17 Copyright © 2004, Oracle. All rights reserved. Defining Constraints

8-18 Copyright © 2004, Oracle. All rights reserved. Viewing the Attributes of a Table

8-19 Copyright © 2004, Oracle. All rights reserved. Viewing the Contents of a Table

8-20 Copyright © 2004, Oracle. All rights reserved. Actions with Tables

8-21 Copyright © 2004, Oracle. All rights reserved. Actions with Tables Full Notes Page

8-22 Copyright © 2004, Oracle. All rights reserved. Creating Indexes

8-23 Copyright © 2004, Oracle. All rights reserved. What Is a View? Tailored representation of data in a table or view Views do not contain data

8-24 Copyright © 2004, Oracle. All rights reserved. Creating Views

8-25 Copyright © 2004, Oracle. All rights reserved. What Is a Sequence?

8-26 Copyright © 2004, Oracle. All rights reserved. What Is a Sequence? Full Notes Page

8-27 Copyright © 2004, Oracle. All rights reserved. Using a Sequence

8-28 Copyright © 2004, Oracle. All rights reserved. Summary In this lesson, you should have learned how to: Create and modify tables Define constraints View the attributes of a table View the contents of a table Create indexes and views

8-29 Copyright © 2004, Oracle. All rights reserved. Practice 8: Working with Tables This practice covers the following: Creating tables and indexes Modifying tables Dropping a table Creating a view

8-30 Copyright © 2004, Oracle. All rights reserved. Practice 8 – Working with Tables Full Notes Page

8-31 Copyright © 2004, Oracle. All rights reserved. Practice 8 – Working with Tables Full Notes Page

8-32 Copyright © 2004, Oracle. All rights reserved. Practice 8 – Working with Tables Full Notes Page