CITATION

Mata-Toledo, Ramon and Cushman, Pauline. Schaum’s Outline of Fundamentals of SQL Programming. McGraw-Hill, 2000.

Schaum’s Outline of Fundamentals of SQL Programming

Published:  September 2000

eISBN: 9780071787536 0071787534 | ISBN: 9780071359535
  • Title Page
  • Copyright Page
  • Dedication
  • Preface
  • Contents
  • Chapter 1: An Introduction to SQL and Relational Database Concepts
  • 1.1 The SQL Language
  • 1.2 Relational Database Management Systems
  • 1.3 Candidate Key and Primary Key of Relation
  • 1.4 Foreign Keys
  • 1.5 Relational Operators
  • 1.5.1 THE SELECTION OPERATOR7
  • 1.5.2 THE PROJECTION OPERATOR
  • 1.5.3 THE EQUIJOIN OPERATOR
  • 1.6 Attribute Domains and Their Implementations
  • 1.7 Name Conventions for Database Objects
  • 1.8 Structure of SQL Statements and SQL Writing Guidelines
  • 1.9 Interacting with the Oracle RDBMS through SQL*Plus
  • 1.10 Creating Tables
  • 1.11 Describing the Structure of a Table
  • 1.12 Populating Tables
  • 1.13 The COMMIT and ROLLBACK Commands
  • 1.14 The SELECT Statement
  • 1.15 The Sample Database
  • 1.15.1 TABLES OF THE SPORTING GOODS DATABASE
  • 1.15.2 REFERENTIAL INTEGRITY CONSTRAINTS OF THE SG DATABASE
  • 1.15.3 ADDITIONAL CONSTRAINTS OF THE SG DATABASE
  • 1.16 Updating and Deleting Rows of a Table
  • 1.16.1 THE UPDATE TABLE COMMAND
  • 1.16.2 THE DELETE AND THE TRUNCATE COMMANDS
  • 1.16.3 THE DROP TABLE COMMAND
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Chapter 2: Implementation of the Relational Operators in SQL
  • 2.1 Implementation of the Selection Operator
  • 2.2 Using Aliases to Control Column Headings
  • 2.3 Implementation of the Projection Operator
  • 2.4 Implementation of the Join Operator
  • 2.4.1 THE EQUIJOIN
  • 2.4.2 USING TABLE ALIASES TO SIMPLIFY QUERIES
  • 2.4.3 USING LITERALS AND THE CONCATENATION OPERATOR TO MODIFY QUERY RESULTS
  • 2.4.4 SELF JOIN
  • 2.4.5 Outer Join
  • 2.5 Creating Foreign Keys
  • 2.5.1 DEFINING FOREIGN KEYS AT THE TIME A TABLE IS CREATED
  • 2.5.2 DEFINING FOREIGN KEYS IN AN EXISTING TABLE
  • 2.6 De.ning Primary Keys in an Existing Table
  • 2.7 Using CHECK Constraints to Restrict a Column’s Input Values
  • 2.8 Adding Columns to an Existing Table
  • 2.9 Modifying Columns of an Existing Table
  • 2.10 Removing Constraints from a Table
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Chapter 3: Boolean Operators and Pattern Matching
  • 3.1 Boolean Operators and Their Use in Compound Clauses
  • 3.1.1 THE AND OPERATOR
  • 3.1.2 THE OR OPERATOR
  • 3.1.3 THE NOT OPERATOR
  • 3.1.4 ORDER OF PRECEDENCE FOR COMPOUND CONDITIONS
  • 3.2 Pattern Matching—the LIKE Statement and Wildcard Characters
  • 3.2.1 PERCENT SIGN (%)
  • 3.2.2 UNDERLINE CHARACTER (_)
  • 3.3 Matching Values in a List or a Range of Values
  • 3.3.1 THE BETWEEN OPERATOR
  • 3.3.2 THE IN OPERATOR
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Chapter 4: Arithmetic Operations and Built-In Functions
  • 4.1 Arithmetic Operations
  • 4.2 Built-In Functions
  • 4.3 Built-In Functions—Individual Numeric
  • 4.3.1 THE ABS(m) FUNCTION
  • 4.3.2 THE MOD( m,n) FUNCTION
  • 4.3.3 THE POWER( m,n) FUNCTION
  • 4.3.4 THE ROUND(m [,n]) FUNCTION
  • 4.3.5 THE TRUNC( m,[n]) FUNCTION
  • 4.3.6 NESTING THE FUNCTIONS
  • 4.4 Built-In Functions—Character
  • 4.4.1 THE CASE CONVERSION FUNCTIONS
  • 4.4.2 THE CONCATENATING FUNCTION
  • 4.4.3 THE PADDING AND TRIMMING FUNCTIONS
  • 4.4.4 THE REPLACING FUNCTION
  • 4.4.5 THE SUBSTRING FUNCTION
  • 4.4.6 FUNCTIONS RETURNING INTEGERS
  • 4.5 Important Conversion Functions
  • 4.5.1 USING OPERATIONS OR FUNCTIONS ON NULL VALUES
  • 4.5.2 CONVERTING BETWEEN STRINGS AND NUMBERS
  • Solved Problems
  • Solved Problems
  • Answers to Supplementary Problems
  • Chapter 5: Group Functions
  • 5.1 Introduction to Group Functions
  • 5.2 The SUM( n) and AVG( n) Functions
  • 5.3 T he MAX( n) and MIN( n) Functions
  • 5.4 The COUNT( ) Functions
  • 5.4.1 THE COUNT(*) FUNCTION
  • 5.4.2 THE COUNT(ALL n) AND COUNT( n) FUNCTIONS
  • 5.4.3 THE COUNT(DISTINCT n) FUNCTION
  • 5.5 Combining Single-Value and Group Functions
  • 5.6 Displaying Speci.c Groups
  • 5.6.1 THE GROUP BY CLAUSE
  • 5.6.2 THE HAVING CLAUSE
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Chapter 6: Processing Date and Time Information
  • 6.1 Introduction to Processing Date and Time
  • 6.2 Arithmetic with Dates
  • 6.3 Date Functions
  • 6.3.1 THE SYSDATE FUNCTION
  • 6.3.2 DAY AND MONTH FUNCTIONS
  • 6.4 Formatting Dates and Times
  • 6.4.1 TO DATE( ) AND TO CHAR( ) FUNCTIONS AND FORMATTING
  • 6.4.2 ROUND( ) AND TRUNC( ) FUNCTIONS
  • 6.4.3 GREATEST( ) AND LEAST( ) FUNCTIONS
  • 6.4.4 NEW_TIME( ) FUNCTION
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Chapter 7: Complex Queries and Set Operators
  • 7.1 Subqueries
  • 7.1.1 SINGLE-ROW SUBQUERIES
  • 7.1.2 MULTIPLE-ROW SUBQUERIES
  • 7.1.3 MULTIPLE-COLUMN SUBQUERIES
  • 7.2 Correlated Queries
  • 7.3 Using Subqueries to Create Tables
  • 7.3.1 COPYING THE STRUCTURE OF A TABLE
  • 7.3.2 COPYING SELECTED COLUMNS OF A TABLE AND THEIR DATA
  • 7.4 Updating a Table Using Subqueries
  • 7.5 Inserting Values into a Table Using Subqueries
  • 7.6 Deleting Rows from a Table Using Subqueries
  • 7.7 Set Operators
  • 7.7.1 THE UNION OPERATOR
  • 7.7.2 THE INTERSECT OPERATOR
  • 7.7.3 THE MINUS OPERATOR
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Chapter 8: Basic Security Issues Using SQL
  • 8.1 Data Security
  • 8.1.1 AUTHENTICATION
  • 8.1.2 AUTHORIZATION
  • 8.1.2.1 Creating Users
  • 8.1.2.2 Dropping Users
  • 8.1.2.3 Monitoring Users
  • 8.1.2.4 Granting System Privileges to Users
  • 8.1.2.5 GRANTING OBJECTS PRIVILEGES TO USERS
  • 8.2 Hiding Data Through Views
  • 8.2.1 CREATING VIEWS
  • 8.2.2 UPDATING VIEWS
  • Solved Problems
  • Supplementary Problems
  • Answers to Supplementary Problems
  • Appendix A: Using Personal Oracle
  • Appendix B: SQL Reserved Words
  • Appendix C: Syntax Diagrams of a Subset of SQL
  • Appendix D: E-R Diagram, Sporting Goods Database Scripts, and Other Scripts
  • Other Database Scripts Used
  • Appendix E: Creating Reports Using SQL*Plus
  • System Variables and the SET Command
  • Formatting Commands
  • Using the BREAK Command1
  • Calculations Within Reports
  • Additional Features of the TTITLE and BTITLE Commands
  • Entering Top and Bottom Titles Interactively
  • Index