100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached 4.6 TrustPilot
logo-home
Exam (elaborations)

Sophia Introduction to Relational Databases Milestone one, score 33/36, 92%

Rating
-
Sold
-
Pages
40
Grade
A+
Uploaded on
07-10-2023
Written in
2023/2024

Sophia Introduction to Relational Databases Milestone one, score 33/36, 92% 33 / 36  that's 92% RETAKE  33 questions were answered correctly . 3 questions were answered incorrectly . In each milestone, you may want or need to use the databaseand query tool to answer some of the questions. We suggest youopen the tool in another browser tab while you are working onthis assessment. Identify the correctly constructed ALTER TABLE statement toadd a UNIQUE constraint to the column reference_number withthe constraint name reference_number_unique on the tablecalled 'document'.   ALTER TABLE document ADDCONSTRAINT reference_numberUNIQUE (reference_number);  ALTER TABLE document ADDCONSTRAINTreference_number_uniqueUNIQUE (reference_number

Show more Read less
Institution
Course











Whoops! We can’t load your doc right now. Try again or contact support.

Written for

Course

Document information

Uploaded on
October 7, 2023
Number of pages
40
Written in
2023/2024
Type
Exam (elaborations)
Contains
Questions & answers

Subjects

Content preview

UNIT 1 — MILESTONE 1

33/36

33/36  that's 92% RETAKE



 33 questions were answered correctly.
3 questions were answered incorrectly.



1 


In each milestone, you may want or need to use the database
and query tool to answer some of the questions. We suggest you
open the tool in another browser tab while you are working on
this assessment.

https://postgres.sophia.org/

Identify the correctly constructed ALTER TABLE statement to
add a UNIQUE constraint to the column reference_number with
the constraint name reference_number_unique on the table
called 'document'.



ALTER TABLE document ADD
CONSTRAINT reference_number

UNIQUE (reference_number);



ALTER TABLE document ADD
CONSTRAINT
  reference_number_unique
UNIQUE (reference_number);



ALTER TABLE document ADD
UNIQUE reference_number


, CONSTRAINT
UNIT 1(reference_number_unique);
— MILESTONE 1

33/36
ALTER TABLE document ADD
CONSTRAINT reference_number
 UNIQUE
(reference_number_unique);




RATIONALE
Common mistakes with adding the UNIQUE constraint to an
existing column include not having ( ) around the column names,
omitting the keyword UNIQUE, incorrectly spelling the column
name, and not including the constraint name.

CONCEPT
 UNIQUE to Validate Data

Report an issue with this question




2 


In each milestone, you may want or need to use the database
and query tool to answer some of the questions. We suggest you
open the tool in another browser tab while you are working on
this assessment.

https://postgres.sophia.org/

Using the SELECT statement, query the track table to find the
total cost of the tracks on album_id 5, rounded to the nearest
dollar.



14


, UNIT

114.9
— MILESTONE 1

33/36
14.85




15
 



RATIONALE
Common mistakes when using the ROUND function include not
selecting the right column, not including the precision level,
omitting the ( ) around the column/function, and failing to add in the
filter conditions.

CONCEPT
 ROUND to Round Numbers

Report an issue with this question




3 


In each milestone, you may want or need to use the database
and query tool to answer some of the questions. We suggest you
open the tool in another browser tab while you are working on
this assessment.

https://postgres.sophia.org/

Using the AND or OR statement, filter the employee table for
employees who live in the city Lethbridge or have IT within their
title.

Identify the first name of the 2nd record.



Michael


, UNIT 1Robert
— MILESTONE 1
 

33/36
Laura
 



King




RATIONALE
Common mistakes include using the = instead of LIKE when
utilizing wild cards, filtering the wrong column of data, using the
wrong data table, omitting the single quotes around the data, and
forgetting to include the wild cards in all parts of the string rather
than just on one end. Another common mistake when using the
AND and OR statements is selecting the incorrect option; the AND
operator should be used when both conditions need to apply
whereas the OR operator should be used when only one condition
of the two should apply.

CONCEPT
 Multiple Filters

Report an issue with this question




4 


In each milestone, you may want or need to use the database
and query tool to answer some of the questions. We suggest you
open the tool in another browser tab while you are working on
this assessment.

https://postgres.sophia.org/

Using the WHERE clause, filter the employee table to include
individuals that report to Andrew Adams, who has an
employee_id of 1.

Identify the title of the 2nd individual listed.

Get to know the seller

Seller avatar
Reputation scores are based on the amount of documents a seller has sold for a fee and the reviews they have received for those documents. There are three levels: Bronze, Silver and Gold. The better the reputation, the more your can rely on the quality of the sellers work.
LectDan Teachme2-tutor
Follow You need to be logged in order to follow users or courses
Sold
214
Member since
3 year
Number of followers
157
Documents
7577
Last sold
2 days ago

4.1

46 reviews

5
25
4
12
3
1
2
3
1
5

Recently viewed by you

Why students choose Stuvia

Created by fellow students, verified by reviews

Quality you can trust: written by students who passed their tests and reviewed by others who've used these notes.

Didn't get what you expected? Choose another document

No worries! You can instantly pick a different document that better fits what you're looking for.

Pay as you like, start learning right away

No subscription, no commitments. Pay the way you're used to via credit card and download your PDF document instantly.

Student with book image

“Bought, downloaded, and aced it. It really can be that simple.”

Alisha Student

Frequently asked questions