SlideShare a Scribd company logo
F0004
04 Quiz 1 Answer Key *Property of STI
Page 1 of 2
QUIZ
PROBLEM SET. Provide the answer for each question. (5 pts. each)
1. Define database.
A database is a collection of data organized in a structured format defined by metadata
that describes the structure.
2. Differentiate the first normal form from the second normal form.
According to the first normal form, each attribute of a tuple must contain only one
value, each tuple in a relation must contain the same number of values and each tuple in a
relation must be different. According to the second normal form, a relation must be in first
normal form and all attributes in a relation must be dependent on the entire candidate key.
3. Enumerate the three primary types of relationships supported by a relational database.
a. One-to-One
b. One-to-Many
c. Many-to-Many
4. Differentiate a DDL statement from a DML statement.
DDL statements are used to create, modify, and delete database objects such as tables,
views, schemas, domains, triggers, and stored procedures. DML statements are used to view,
add, modify or delete data stored in the database objects.
5. Define schema.
A schema is a set of related objects that are collected under a common namespace.
The schema acts as a container for those objects, which in turn store the SQL data or perform
other data-related functions.
6. Assume that you are writing a SELECT statement that retrieves the CDTitle column and all rows
from the Inventory table. You want the column in the query results to be named CompactDisc.
Provide the SELECT statement that you will use.
SELECT CDTitle AS CompactDisc FROM Inventory;
7. Assume that you are writing a SELECT statement that retrieves the Category and Price columns
from the CompactDiscStock table. You want to group together the data first by the Category
column and then by the Price column. And then you want to filter out any groups that have a
Price value over 15.99. Provide the SELECT statement that you will use.
SELECT Category, Price FROM CompactDiscStock
GROUP BY Category, Price
HAVING Price < 16.00 ;
8. Assume that you are creating an INSERT statement to insert data into the ArtistTypes table. The
table includes only two columns: ArtID and TypeName. You want to insert one row that includes
the ArtID value of 27 and the TypeName value of Gospel. Provide SQL statement that you will
use.
INSERT INTO ArtistTypes VALUES ( 27, 'Gospel' ) ;
9. Assume that you are creating an UPDATE statement to update data in the PerformingArtists
table. And you want to update the ArtID value of every row to 27. Provide SQL statement that
you will use.
UPDATE PerformingArtists SET ArtID = 27 ;
F0004
04 Quiz 1 Answer Key *Property of STI
Page 2 of 2
10. Differentiate an inner join from an outer join.
The inner join combines two tables having a common column which is usually the
primary key. An outer join produces all rows that exist in one table, even if there are
corresponding rows that do not exist in the joined table. In most implementations, the outer
join is broken down into joins called left outer join, right outer join, and full outer join. The
outer join in these implementations is normally optional.
11. Define recursive common table expression.
Recursive common table expressions allow you to query tables that represent
hierarchical information such as reporting relationships within a company. Common table
expressions are recursive when the RECURSIVE keyword appears immediately after WITH.
Recursive common table expressions provide a convenient way to write queries that return
relationships to an arbitrary depth. For example, given a table that represents the reporting
relationships within a company, you can readily write a query that returns all the employees
that report to one particular person.
12. Differentiate a ROLLUP operation from a CUBE operation.
The ROLLUP operation is used when you want to get a result set showing totals and
subtotals. It adds subtotal rows into the result sets of queries with GROUP BY clauses. ROLLUP
generates a result set showing aggregates for a hierarchy of values. The CUBE operation is
useful when you want to work with a large amount of data in your reports. The CUBE operator
provides subtotals of aggregate values in the result set. It produces subtotals for all possible
combinations of the columns listed in the group by clause. When the CUBE operation is
performed on variables, the result set includes many subtotal rows based on combinations of the
values of the variables.

More Related Content

What's hot

Chapter 5 exercises Balagurusamy Programming ANSI in c
Chapter 5 exercises Balagurusamy Programming ANSI  in cChapter 5 exercises Balagurusamy Programming ANSI  in c
Chapter 5 exercises Balagurusamy Programming ANSI in c
BUBT
 
Introduction to BOOTSTRAP
Introduction to BOOTSTRAPIntroduction to BOOTSTRAP
Introduction to BOOTSTRAP
Jeanie Arnoco
 
Bootstrap ppt
Bootstrap pptBootstrap ppt
Bootstrap ppt
Nidhi mishra
 
html tags
 html tags html tags
html tags
YogeshDhamke2
 
Data visualization using R
Data visualization using RData visualization using R
Data visualization using R
Ummiya Mohammedi
 
HTML CSS & Javascript
HTML CSS & JavascriptHTML CSS & Javascript
HTML CSS & Javascript
David Lindkvist
 
R and Visualization: A match made in Heaven
R and Visualization: A match made in HeavenR and Visualization: A match made in Heaven
R and Visualization: A match made in Heaven
Edureka!
 
Arrays in python
Arrays in pythonArrays in python
Arrays in python
Lifna C.S
 
Using Adjustment Layers and Lighting in Photoshop
Using Adjustment Layers and Lighting in PhotoshopUsing Adjustment Layers and Lighting in Photoshop
Using Adjustment Layers and Lighting in Photoshop
nombre thera
 
Bootstrap Part - 1
Bootstrap Part - 1Bootstrap Part - 1
Bootstrap Part - 1
EPAM Systems
 
C# Arrays
C# ArraysC# Arrays
C# Arrays
Hock Leng PUAH
 
DAY 2 - Starting in Photoshop (Images and Layers)
DAY 2 - Starting in Photoshop (Images and Layers)DAY 2 - Starting in Photoshop (Images and Layers)
DAY 2 - Starting in Photoshop (Images and Layers)
Sef Cambaliza
 
Intro to HTML and CSS basics
Intro to HTML and CSS basicsIntro to HTML and CSS basics
Intro to HTML and CSS basics
Eliran Eliassy
 
Library functions in c++
Library functions in c++Library functions in c++
Library functions in c++
Neeru Mittal
 
[OOP - Lec 19] Static Member Functions
[OOP - Lec 19] Static Member Functions[OOP - Lec 19] Static Member Functions
[OOP - Lec 19] Static Member Functions
Muhammad Hammad Waseem
 
Let us c chapter 4 solution
Let us c chapter 4 solutionLet us c chapter 4 solution
Let us c chapter 4 solution
rohit kumar
 
Actionscript 3 - Session 3 Action Script And Flash
Actionscript 3 - Session 3 Action Script And FlashActionscript 3 - Session 3 Action Script And Flash
Actionscript 3 - Session 3 Action Script And Flash
OUM SAOKOSAL
 
Programming fundamentals using c++ question paper 2014 tutorialsduniya
Programming fundamentals using c++  question paper 2014   tutorialsduniyaProgramming fundamentals using c++  question paper 2014   tutorialsduniya
Programming fundamentals using c++ question paper 2014 tutorialsduniya
TutorialsDuniya.com
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
Seble Nigussie
 
String in python use of split method
String in python use of split methodString in python use of split method
String in python use of split method
vikram mahendra
 

What's hot (20)

Chapter 5 exercises Balagurusamy Programming ANSI in c
Chapter 5 exercises Balagurusamy Programming ANSI  in cChapter 5 exercises Balagurusamy Programming ANSI  in c
Chapter 5 exercises Balagurusamy Programming ANSI in c
 
Introduction to BOOTSTRAP
Introduction to BOOTSTRAPIntroduction to BOOTSTRAP
Introduction to BOOTSTRAP
 
Bootstrap ppt
Bootstrap pptBootstrap ppt
Bootstrap ppt
 
html tags
 html tags html tags
html tags
 
Data visualization using R
Data visualization using RData visualization using R
Data visualization using R
 
HTML CSS & Javascript
HTML CSS & JavascriptHTML CSS & Javascript
HTML CSS & Javascript
 
R and Visualization: A match made in Heaven
R and Visualization: A match made in HeavenR and Visualization: A match made in Heaven
R and Visualization: A match made in Heaven
 
Arrays in python
Arrays in pythonArrays in python
Arrays in python
 
Using Adjustment Layers and Lighting in Photoshop
Using Adjustment Layers and Lighting in PhotoshopUsing Adjustment Layers and Lighting in Photoshop
Using Adjustment Layers and Lighting in Photoshop
 
Bootstrap Part - 1
Bootstrap Part - 1Bootstrap Part - 1
Bootstrap Part - 1
 
C# Arrays
C# ArraysC# Arrays
C# Arrays
 
DAY 2 - Starting in Photoshop (Images and Layers)
DAY 2 - Starting in Photoshop (Images and Layers)DAY 2 - Starting in Photoshop (Images and Layers)
DAY 2 - Starting in Photoshop (Images and Layers)
 
Intro to HTML and CSS basics
Intro to HTML and CSS basicsIntro to HTML and CSS basics
Intro to HTML and CSS basics
 
Library functions in c++
Library functions in c++Library functions in c++
Library functions in c++
 
[OOP - Lec 19] Static Member Functions
[OOP - Lec 19] Static Member Functions[OOP - Lec 19] Static Member Functions
[OOP - Lec 19] Static Member Functions
 
Let us c chapter 4 solution
Let us c chapter 4 solutionLet us c chapter 4 solution
Let us c chapter 4 solution
 
Actionscript 3 - Session 3 Action Script And Flash
Actionscript 3 - Session 3 Action Script And FlashActionscript 3 - Session 3 Action Script And Flash
Actionscript 3 - Session 3 Action Script And Flash
 
Programming fundamentals using c++ question paper 2014 tutorialsduniya
Programming fundamentals using c++  question paper 2014   tutorialsduniyaProgramming fundamentals using c++  question paper 2014   tutorialsduniya
Programming fundamentals using c++ question paper 2014 tutorialsduniya
 
Introduction to HTML
Introduction to HTMLIntroduction to HTML
Introduction to HTML
 
String in python use of split method
String in python use of split methodString in python use of split method
String in python use of split method
 

Viewers also liked

Cormac McCarthy's The Road quiz #1
Cormac McCarthy's The Road quiz #1Cormac McCarthy's The Road quiz #1
Cormac McCarthy's The Road quiz #1
Victoria Wooldridge
 
Cormac McCarthy's The road quiz #2
Cormac McCarthy's The road quiz #2Cormac McCarthy's The road quiz #2
Cormac McCarthy's The road quiz #2
Victoria Wooldridge
 
The Road Study Guide
The Road Study GuideThe Road Study Guide
The Road Study Guide
cinbarnsley
 
enotes-road-mccarthy-summary
enotes-road-mccarthy-summaryenotes-road-mccarthy-summary
enotes-road-mccarthy-summary
MStultz72
 
Cormac McCarthy's The Road quiz #3
Cormac McCarthy's The Road quiz #3Cormac McCarthy's The Road quiz #3
Cormac McCarthy's The Road quiz #3
Victoria Wooldridge
 
The Road, by Cormac McCarthy
The Road, by Cormac McCarthyThe Road, by Cormac McCarthy
The Road, by Cormac McCarthy
Victoria Wooldridge
 
Reading quiz 2 grade 10
Reading quiz 2 grade 10Reading quiz 2 grade 10
Reading quiz 2 grade 10
seraja
 
Debates2012
Debates2012Debates2012
Debates2012
Victoria Wooldridge
 
Cormac Mccarthy author presentation
Cormac Mccarthy author presentationCormac Mccarthy author presentation
Cormac Mccarthy author presentation
mdasse
 
Opening section the road annotated
Opening section the road annotatedOpening section the road annotated
Opening section the road annotated
cinbarnsley
 

Viewers also liked (10)

Cormac McCarthy's The Road quiz #1
Cormac McCarthy's The Road quiz #1Cormac McCarthy's The Road quiz #1
Cormac McCarthy's The Road quiz #1
 
Cormac McCarthy's The road quiz #2
Cormac McCarthy's The road quiz #2Cormac McCarthy's The road quiz #2
Cormac McCarthy's The road quiz #2
 
The Road Study Guide
The Road Study GuideThe Road Study Guide
The Road Study Guide
 
enotes-road-mccarthy-summary
enotes-road-mccarthy-summaryenotes-road-mccarthy-summary
enotes-road-mccarthy-summary
 
Cormac McCarthy's The Road quiz #3
Cormac McCarthy's The Road quiz #3Cormac McCarthy's The Road quiz #3
Cormac McCarthy's The Road quiz #3
 
The Road, by Cormac McCarthy
The Road, by Cormac McCarthyThe Road, by Cormac McCarthy
The Road, by Cormac McCarthy
 
Reading quiz 2 grade 10
Reading quiz 2 grade 10Reading quiz 2 grade 10
Reading quiz 2 grade 10
 
Debates2012
Debates2012Debates2012
Debates2012
 
Cormac Mccarthy author presentation
Cormac Mccarthy author presentationCormac Mccarthy author presentation
Cormac Mccarthy author presentation
 
Opening section the road annotated
Opening section the road annotatedOpening section the road annotated
Opening section the road annotated
 

Similar to 04 quiz 1 answer key

Database Architecture and Basic Concepts
Database Architecture and Basic ConceptsDatabase Architecture and Basic Concepts
Database Architecture and Basic Concepts
Tony Wong
 
Fg d
Fg dFg d
Fg d
Taha Khan
 
Database DESIGN CONCEPTSDr. Dexter Francis2Data Design
Database DESIGN CONCEPTSDr. Dexter Francis2Data DesignDatabase DESIGN CONCEPTSDr. Dexter Francis2Data Design
Database DESIGN CONCEPTSDr. Dexter Francis2Data Design
OllieShoresna
 
PPT of Common Table Expression (CTE), Window Functions, JOINS, SubQuery
PPT  of Common Table Expression (CTE), Window Functions, JOINS, SubQueryPPT  of Common Table Expression (CTE), Window Functions, JOINS, SubQuery
PPT of Common Table Expression (CTE), Window Functions, JOINS, SubQuery
Abhishek590097
 
Module 3
Module 3Module 3
Module 3
cs19club
 
Understanding about relational database m-square systems inc
Understanding about relational database m-square systems incUnderstanding about relational database m-square systems inc
Understanding about relational database m-square systems inc
Muthu Natarajan
 
SQLSERVERQUERIES.pptx
SQLSERVERQUERIES.pptxSQLSERVERQUERIES.pptx
SQLSERVERQUERIES.pptx
ssuser6bf2d1
 
SQL Server Learning Drive
SQL Server Learning Drive SQL Server Learning Drive
SQL Server Learning Drive
TechandMate
 
Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2
Techglyphs
 
The Database Environment Chapter 8
The Database Environment Chapter 8The Database Environment Chapter 8
The Database Environment Chapter 8
Jeanie Arnoco
 
SQL -Beginner To Intermediate Level.pdf
SQL -Beginner To Intermediate Level.pdfSQL -Beginner To Intermediate Level.pdf
SQL -Beginner To Intermediate Level.pdf
DraguClaudiu
 
T-SQL Overview
T-SQL OverviewT-SQL Overview
T-SQL Overview
Ahmed Elbaz
 
Day-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptxDay-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptx
uzmasulthana3
 
Ms sql server ii
Ms sql server  iiMs sql server  ii
Ms sql server ii
Iblesoft
 
SQL Commands
SQL Commands SQL Commands
SQL Commands
Divyank Jindal
 
Chapter 4 Structured Query Language
Chapter 4 Structured Query LanguageChapter 4 Structured Query Language
Chapter 4 Structured Query Language
Eddyzulham Mahluzydde
 
Unit1
Unit1Unit1
Unit1
Jay Patel
 
Physical elements of data
Physical elements of dataPhysical elements of data
Physical elements of data
Dimara Hakim
 
Review of SQL
Review of SQLReview of SQL
Review of SQL
Information Technology
 
Steps towards of sql server developer
Steps towards of sql server developerSteps towards of sql server developer
Steps towards of sql server developer
Ahsan Kabir
 

Similar to 04 quiz 1 answer key (20)

Database Architecture and Basic Concepts
Database Architecture and Basic ConceptsDatabase Architecture and Basic Concepts
Database Architecture and Basic Concepts
 
Fg d
Fg dFg d
Fg d
 
Database DESIGN CONCEPTSDr. Dexter Francis2Data Design
Database DESIGN CONCEPTSDr. Dexter Francis2Data DesignDatabase DESIGN CONCEPTSDr. Dexter Francis2Data Design
Database DESIGN CONCEPTSDr. Dexter Francis2Data Design
 
PPT of Common Table Expression (CTE), Window Functions, JOINS, SubQuery
PPT  of Common Table Expression (CTE), Window Functions, JOINS, SubQueryPPT  of Common Table Expression (CTE), Window Functions, JOINS, SubQuery
PPT of Common Table Expression (CTE), Window Functions, JOINS, SubQuery
 
Module 3
Module 3Module 3
Module 3
 
Understanding about relational database m-square systems inc
Understanding about relational database m-square systems incUnderstanding about relational database m-square systems inc
Understanding about relational database m-square systems inc
 
SQLSERVERQUERIES.pptx
SQLSERVERQUERIES.pptxSQLSERVERQUERIES.pptx
SQLSERVERQUERIES.pptx
 
SQL Server Learning Drive
SQL Server Learning Drive SQL Server Learning Drive
SQL Server Learning Drive
 
Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2Bt0075 rdbms with mysql 2
Bt0075 rdbms with mysql 2
 
The Database Environment Chapter 8
The Database Environment Chapter 8The Database Environment Chapter 8
The Database Environment Chapter 8
 
SQL -Beginner To Intermediate Level.pdf
SQL -Beginner To Intermediate Level.pdfSQL -Beginner To Intermediate Level.pdf
SQL -Beginner To Intermediate Level.pdf
 
T-SQL Overview
T-SQL OverviewT-SQL Overview
T-SQL Overview
 
Day-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptxDay-2 SQL Theory_V1.pptx
Day-2 SQL Theory_V1.pptx
 
Ms sql server ii
Ms sql server  iiMs sql server  ii
Ms sql server ii
 
SQL Commands
SQL Commands SQL Commands
SQL Commands
 
Chapter 4 Structured Query Language
Chapter 4 Structured Query LanguageChapter 4 Structured Query Language
Chapter 4 Structured Query Language
 
Unit1
Unit1Unit1
Unit1
 
Physical elements of data
Physical elements of dataPhysical elements of data
Physical elements of data
 
Review of SQL
Review of SQLReview of SQL
Review of SQL
 
Steps towards of sql server developer
Steps towards of sql server developerSteps towards of sql server developer
Steps towards of sql server developer
 

More from Anne Lee

Week 17 slides 1 7 multidimensional, parallel, and distributed database
Week 17 slides 1 7 multidimensional, parallel, and distributed databaseWeek 17 slides 1 7 multidimensional, parallel, and distributed database
Week 17 slides 1 7 multidimensional, parallel, and distributed database
Anne Lee
 
Data mining
Data miningData mining
Data mining
Anne Lee
 
Data warehousing
Data warehousingData warehousing
Data warehousing
Anne Lee
 
Database backup and recovery
Database backup and recoveryDatabase backup and recovery
Database backup and recovery
Anne Lee
 
Database monitoring and performance management
Database monitoring and performance managementDatabase monitoring and performance management
Database monitoring and performance management
Anne Lee
 
transportation and assignment models
transportation and assignment modelstransportation and assignment models
transportation and assignment models
Anne Lee
 
Database Security Slide Handout
Database Security Slide HandoutDatabase Security Slide Handout
Database Security Slide Handout
Anne Lee
 
Database Security Handout
Database Security HandoutDatabase Security Handout
Database Security Handout
Anne Lee
 
Database Security - IG
Database Security - IGDatabase Security - IG
Database Security - IG
Anne Lee
 
03 laboratory exercise 1 - WORKING WITH CTE
03 laboratory exercise 1 - WORKING WITH CTE03 laboratory exercise 1 - WORKING WITH CTE
03 laboratory exercise 1 - WORKING WITH CTE
Anne Lee
 
02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES
02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES
02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES
Anne Lee
 
01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION
01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION
01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION
Anne Lee
 
Indexes - INSTRUCTOR'S GUIDE
Indexes - INSTRUCTOR'S GUIDEIndexes - INSTRUCTOR'S GUIDE
Indexes - INSTRUCTOR'S GUIDE
Anne Lee
 
07 ohp slides 1 - INDEXES
07 ohp slides 1 - INDEXES07 ohp slides 1 - INDEXES
07 ohp slides 1 - INDEXES
Anne Lee
 
07 ohp slide handout 1 - INDEXES
07 ohp slide handout 1 - INDEXES07 ohp slide handout 1 - INDEXES
07 ohp slide handout 1 - INDEXES
Anne Lee
 
Wk 16 ses 43 45 makrong kasanayan sa pagsusulat
Wk 16 ses 43 45 makrong kasanayan sa pagsusulatWk 16 ses 43 45 makrong kasanayan sa pagsusulat
Wk 16 ses 43 45 makrong kasanayan sa pagsusulat
Anne Lee
 
Wk 15 ses 40 42 makrong kasanayan sa pagbabasa
Wk 15 ses 40 42 makrong kasanayan sa pagbabasaWk 15 ses 40 42 makrong kasanayan sa pagbabasa
Wk 15 ses 40 42 makrong kasanayan sa pagbabasa
Anne Lee
 
Wk 13 ses 35 37 makrong kasanayan sa pagsasalita
Wk 13 ses 35 37 makrong kasanayan sa pagsasalitaWk 13 ses 35 37 makrong kasanayan sa pagsasalita
Wk 13 ses 35 37 makrong kasanayan sa pagsasalita
Anne Lee
 
Wk 12 ses 32 34 makrong kasanayan sa pakikinig
Wk 12 ses 32 34 makrong kasanayan sa pakikinigWk 12 ses 32 34 makrong kasanayan sa pakikinig
Wk 12 ses 32 34 makrong kasanayan sa pakikinig
Anne Lee
 
Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1
Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1
Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1
Anne Lee
 

More from Anne Lee (20)

Week 17 slides 1 7 multidimensional, parallel, and distributed database
Week 17 slides 1 7 multidimensional, parallel, and distributed databaseWeek 17 slides 1 7 multidimensional, parallel, and distributed database
Week 17 slides 1 7 multidimensional, parallel, and distributed database
 
Data mining
Data miningData mining
Data mining
 
Data warehousing
Data warehousingData warehousing
Data warehousing
 
Database backup and recovery
Database backup and recoveryDatabase backup and recovery
Database backup and recovery
 
Database monitoring and performance management
Database monitoring and performance managementDatabase monitoring and performance management
Database monitoring and performance management
 
transportation and assignment models
transportation and assignment modelstransportation and assignment models
transportation and assignment models
 
Database Security Slide Handout
Database Security Slide HandoutDatabase Security Slide Handout
Database Security Slide Handout
 
Database Security Handout
Database Security HandoutDatabase Security Handout
Database Security Handout
 
Database Security - IG
Database Security - IGDatabase Security - IG
Database Security - IG
 
03 laboratory exercise 1 - WORKING WITH CTE
03 laboratory exercise 1 - WORKING WITH CTE03 laboratory exercise 1 - WORKING WITH CTE
03 laboratory exercise 1 - WORKING WITH CTE
 
02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES
02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES
02 laboratory exercise 1 - RETRIEVING DATA FROM SEVERAL TABLES
 
01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION
01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION
01 laboratory exercise 1 - DESIGN A SIMPLE DATABASE APPLICATION
 
Indexes - INSTRUCTOR'S GUIDE
Indexes - INSTRUCTOR'S GUIDEIndexes - INSTRUCTOR'S GUIDE
Indexes - INSTRUCTOR'S GUIDE
 
07 ohp slides 1 - INDEXES
07 ohp slides 1 - INDEXES07 ohp slides 1 - INDEXES
07 ohp slides 1 - INDEXES
 
07 ohp slide handout 1 - INDEXES
07 ohp slide handout 1 - INDEXES07 ohp slide handout 1 - INDEXES
07 ohp slide handout 1 - INDEXES
 
Wk 16 ses 43 45 makrong kasanayan sa pagsusulat
Wk 16 ses 43 45 makrong kasanayan sa pagsusulatWk 16 ses 43 45 makrong kasanayan sa pagsusulat
Wk 16 ses 43 45 makrong kasanayan sa pagsusulat
 
Wk 15 ses 40 42 makrong kasanayan sa pagbabasa
Wk 15 ses 40 42 makrong kasanayan sa pagbabasaWk 15 ses 40 42 makrong kasanayan sa pagbabasa
Wk 15 ses 40 42 makrong kasanayan sa pagbabasa
 
Wk 13 ses 35 37 makrong kasanayan sa pagsasalita
Wk 13 ses 35 37 makrong kasanayan sa pagsasalitaWk 13 ses 35 37 makrong kasanayan sa pagsasalita
Wk 13 ses 35 37 makrong kasanayan sa pagsasalita
 
Wk 12 ses 32 34 makrong kasanayan sa pakikinig
Wk 12 ses 32 34 makrong kasanayan sa pakikinigWk 12 ses 32 34 makrong kasanayan sa pakikinig
Wk 12 ses 32 34 makrong kasanayan sa pakikinig
 
Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1
Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1
Wk 11 ses 29 31 konseptong pangkomunikasyon - FILIPINO 1
 

Recently uploaded

Hand Rolled Applicative User Validation Code Kata
Hand Rolled Applicative User ValidationCode KataHand Rolled Applicative User ValidationCode Kata
Hand Rolled Applicative User Validation Code Kata
Philip Schwarz
 
Malibou Pitch Deck For Its €3M Seed Round
Malibou Pitch Deck For Its €3M Seed RoundMalibou Pitch Deck For Its €3M Seed Round
Malibou Pitch Deck For Its €3M Seed Round
sjcobrien
 
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CDKuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
rodomar2
 
socradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdfsocradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdf
SOCRadar
 
Mobile app Development Services | Drona Infotech
Mobile app Development Services  | Drona InfotechMobile app Development Services  | Drona Infotech
Mobile app Development Services | Drona Infotech
Drona Infotech
 
316895207-SAP-Oil-and-Gas-Downstream-Training.pptx
316895207-SAP-Oil-and-Gas-Downstream-Training.pptx316895207-SAP-Oil-and-Gas-Downstream-Training.pptx
316895207-SAP-Oil-and-Gas-Downstream-Training.pptx
ssuserad3af4
 
Oracle 23c New Features For DBAs and Developers.pptx
Oracle 23c New Features For DBAs and Developers.pptxOracle 23c New Features For DBAs and Developers.pptx
Oracle 23c New Features For DBAs and Developers.pptx
Remote DBA Services
 
GreenCode-A-VSCode-Plugin--Dario-Jurisic
GreenCode-A-VSCode-Plugin--Dario-JurisicGreenCode-A-VSCode-Plugin--Dario-Jurisic
GreenCode-A-VSCode-Plugin--Dario-Jurisic
Green Software Development
 
Microservice Teams - How the cloud changes the way we work
Microservice Teams - How the cloud changes the way we workMicroservice Teams - How the cloud changes the way we work
Microservice Teams - How the cloud changes the way we work
Sven Peters
 
Using Query Store in Azure PostgreSQL to Understand Query Performance
Using Query Store in Azure PostgreSQL to Understand Query PerformanceUsing Query Store in Azure PostgreSQL to Understand Query Performance
Using Query Store in Azure PostgreSQL to Understand Query Performance
Grant Fritchey
 
UI5con 2024 - Bring Your Own Design System
UI5con 2024 - Bring Your Own Design SystemUI5con 2024 - Bring Your Own Design System
UI5con 2024 - Bring Your Own Design System
Peter Muessig
 
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsUI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
Peter Muessig
 
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, FactsALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
Green Software Development
 
Energy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina JonuziEnergy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina Jonuzi
Green Software Development
 
Enums On Steroids - let's look at sealed classes !
Enums On Steroids - let's look at sealed classes !Enums On Steroids - let's look at sealed classes !
Enums On Steroids - let's look at sealed classes !
Marcin Chrost
 
Mobile App Development Company In Noida | Drona Infotech
Mobile App Development Company In Noida | Drona InfotechMobile App Development Company In Noida | Drona Infotech
Mobile App Development Company In Noida | Drona Infotech
Drona Infotech
 
Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
Ayan Halder
 
Oracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptxOracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptx
Remote DBA Services
 
8 Best Automated Android App Testing Tool and Framework in 2024.pdf
8 Best Automated Android App Testing Tool and Framework in 2024.pdf8 Best Automated Android App Testing Tool and Framework in 2024.pdf
8 Best Automated Android App Testing Tool and Framework in 2024.pdf
kalichargn70th171
 
E-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian Companies
E-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian CompaniesE-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian Companies
E-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian Companies
Quickdice ERP
 

Recently uploaded (20)

Hand Rolled Applicative User Validation Code Kata
Hand Rolled Applicative User ValidationCode KataHand Rolled Applicative User ValidationCode Kata
Hand Rolled Applicative User Validation Code Kata
 
Malibou Pitch Deck For Its €3M Seed Round
Malibou Pitch Deck For Its €3M Seed RoundMalibou Pitch Deck For Its €3M Seed Round
Malibou Pitch Deck For Its €3M Seed Round
 
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CDKuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
KuberTENes Birthday Bash Guadalajara - Introducción a Argo CD
 
socradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdfsocradar-q1-2024-aviation-industry-report.pdf
socradar-q1-2024-aviation-industry-report.pdf
 
Mobile app Development Services | Drona Infotech
Mobile app Development Services  | Drona InfotechMobile app Development Services  | Drona Infotech
Mobile app Development Services | Drona Infotech
 
316895207-SAP-Oil-and-Gas-Downstream-Training.pptx
316895207-SAP-Oil-and-Gas-Downstream-Training.pptx316895207-SAP-Oil-and-Gas-Downstream-Training.pptx
316895207-SAP-Oil-and-Gas-Downstream-Training.pptx
 
Oracle 23c New Features For DBAs and Developers.pptx
Oracle 23c New Features For DBAs and Developers.pptxOracle 23c New Features For DBAs and Developers.pptx
Oracle 23c New Features For DBAs and Developers.pptx
 
GreenCode-A-VSCode-Plugin--Dario-Jurisic
GreenCode-A-VSCode-Plugin--Dario-JurisicGreenCode-A-VSCode-Plugin--Dario-Jurisic
GreenCode-A-VSCode-Plugin--Dario-Jurisic
 
Microservice Teams - How the cloud changes the way we work
Microservice Teams - How the cloud changes the way we workMicroservice Teams - How the cloud changes the way we work
Microservice Teams - How the cloud changes the way we work
 
Using Query Store in Azure PostgreSQL to Understand Query Performance
Using Query Store in Azure PostgreSQL to Understand Query PerformanceUsing Query Store in Azure PostgreSQL to Understand Query Performance
Using Query Store in Azure PostgreSQL to Understand Query Performance
 
UI5con 2024 - Bring Your Own Design System
UI5con 2024 - Bring Your Own Design SystemUI5con 2024 - Bring Your Own Design System
UI5con 2024 - Bring Your Own Design System
 
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling ExtensionsUI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
UI5con 2024 - Boost Your Development Experience with UI5 Tooling Extensions
 
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, FactsALGIT - Assembly Line for Green IT - Numbers, Data, Facts
ALGIT - Assembly Line for Green IT - Numbers, Data, Facts
 
Energy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina JonuziEnergy consumption of Database Management - Florina Jonuzi
Energy consumption of Database Management - Florina Jonuzi
 
Enums On Steroids - let's look at sealed classes !
Enums On Steroids - let's look at sealed classes !Enums On Steroids - let's look at sealed classes !
Enums On Steroids - let's look at sealed classes !
 
Mobile App Development Company In Noida | Drona Infotech
Mobile App Development Company In Noida | Drona InfotechMobile App Development Company In Noida | Drona Infotech
Mobile App Development Company In Noida | Drona Infotech
 
Using Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional SafetyUsing Xen Hypervisor for Functional Safety
Using Xen Hypervisor for Functional Safety
 
Oracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptxOracle Database 19c New Features for DBAs and Developers.pptx
Oracle Database 19c New Features for DBAs and Developers.pptx
 
8 Best Automated Android App Testing Tool and Framework in 2024.pdf
8 Best Automated Android App Testing Tool and Framework in 2024.pdf8 Best Automated Android App Testing Tool and Framework in 2024.pdf
8 Best Automated Android App Testing Tool and Framework in 2024.pdf
 
E-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian Companies
E-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian CompaniesE-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian Companies
E-Invoicing Implementation: A Step-by-Step Guide for Saudi Arabian Companies
 

04 quiz 1 answer key

  • 1. F0004 04 Quiz 1 Answer Key *Property of STI Page 1 of 2 QUIZ PROBLEM SET. Provide the answer for each question. (5 pts. each) 1. Define database. A database is a collection of data organized in a structured format defined by metadata that describes the structure. 2. Differentiate the first normal form from the second normal form. According to the first normal form, each attribute of a tuple must contain only one value, each tuple in a relation must contain the same number of values and each tuple in a relation must be different. According to the second normal form, a relation must be in first normal form and all attributes in a relation must be dependent on the entire candidate key. 3. Enumerate the three primary types of relationships supported by a relational database. a. One-to-One b. One-to-Many c. Many-to-Many 4. Differentiate a DDL statement from a DML statement. DDL statements are used to create, modify, and delete database objects such as tables, views, schemas, domains, triggers, and stored procedures. DML statements are used to view, add, modify or delete data stored in the database objects. 5. Define schema. A schema is a set of related objects that are collected under a common namespace. The schema acts as a container for those objects, which in turn store the SQL data or perform other data-related functions. 6. Assume that you are writing a SELECT statement that retrieves the CDTitle column and all rows from the Inventory table. You want the column in the query results to be named CompactDisc. Provide the SELECT statement that you will use. SELECT CDTitle AS CompactDisc FROM Inventory; 7. Assume that you are writing a SELECT statement that retrieves the Category and Price columns from the CompactDiscStock table. You want to group together the data first by the Category column and then by the Price column. And then you want to filter out any groups that have a Price value over 15.99. Provide the SELECT statement that you will use. SELECT Category, Price FROM CompactDiscStock GROUP BY Category, Price HAVING Price < 16.00 ; 8. Assume that you are creating an INSERT statement to insert data into the ArtistTypes table. The table includes only two columns: ArtID and TypeName. You want to insert one row that includes the ArtID value of 27 and the TypeName value of Gospel. Provide SQL statement that you will use. INSERT INTO ArtistTypes VALUES ( 27, 'Gospel' ) ; 9. Assume that you are creating an UPDATE statement to update data in the PerformingArtists table. And you want to update the ArtID value of every row to 27. Provide SQL statement that you will use. UPDATE PerformingArtists SET ArtID = 27 ;
  • 2. F0004 04 Quiz 1 Answer Key *Property of STI Page 2 of 2 10. Differentiate an inner join from an outer join. The inner join combines two tables having a common column which is usually the primary key. An outer join produces all rows that exist in one table, even if there are corresponding rows that do not exist in the joined table. In most implementations, the outer join is broken down into joins called left outer join, right outer join, and full outer join. The outer join in these implementations is normally optional. 11. Define recursive common table expression. Recursive common table expressions allow you to query tables that represent hierarchical information such as reporting relationships within a company. Common table expressions are recursive when the RECURSIVE keyword appears immediately after WITH. Recursive common table expressions provide a convenient way to write queries that return relationships to an arbitrary depth. For example, given a table that represents the reporting relationships within a company, you can readily write a query that returns all the employees that report to one particular person. 12. Differentiate a ROLLUP operation from a CUBE operation. The ROLLUP operation is used when you want to get a result set showing totals and subtotals. It adds subtotal rows into the result sets of queries with GROUP BY clauses. ROLLUP generates a result set showing aggregates for a hierarchy of values. The CUBE operation is useful when you want to work with a large amount of data in your reports. The CUBE operator provides subtotals of aggregate values in the result set. It produces subtotals for all possible combinations of the columns listed in the group by clause. When the CUBE operation is performed on variables, the result set includes many subtotal rows based on combinations of the values of the variables.