Module 6.3.2 Quiz - Introduction to Relational Databases and SQL Answers

Module 6.3.2 Quiz - Introduction to Relational Databases and SQL Answers

1. What is a flat file database?

  • a database that stores records in a single file with no hierarchical structure
  • a database that requires SQL to store, manipulate, and retrieve data
  • a database that is used to store large amounts of complex data
  • a database that stores data in a sheet using a hierarchical tabular format of columns and rows

Explanation: A flat file database stores records in a single file with no hierarchical structure. A relational database requires a SQL to store, manipulate, and retrieve data and is used to store large amounts of complex data. A spreadsheet application stores data in a sheet using a tabular format of columns and rows.

2. Which commonly used SQL statement is necessary to retrieve data from one or more tables in a database?

  • CREATE
  • INSERT
  • SELECT
  • TRUNCATE

Explanation: The SELECT statement is the most used SQL statement and is necessary when you need to retrieve data from one or more tables in a database.

3. Which SQL statement is used to filter data in a database?

  • DISTINCT
  • FROM
  • WHERE
  • ORDER BY

Explanation: The WHERE statement is a conditional statement used to filter the returned results.

4. What is used to show how the tables in a database are related to one another?

  • DML
  • ERD
  • CSV
  • DDL

Explanation: An Entity Relationship Diagram (ERD) shows how database tables are related to one another.

5. In the SQL statement " SELECT genre FROM movies" what is specified by "genre"?

  • the database
  • the folder
  • the column
  • the table

Explanation: The SELECT statement identifies the column in a table from which data is requested. In this example, the data in the "genre" column of the "movies" table is requested.

6. Which structure in a table represents an individual record contained in the database?

  • row
  • relationship
  • foreign key
  • column

Explanation: In a relational database table, each row represents an individual record and the attributes associated with that record.

7. What is represented by the comma-separated list of items following the SELECT command in this example?

SELECT movieID, title

  • aliases
  • columns (attributes)
  • records
  • table names

Explanation: The SELECT command is followed by a list of the columns (attributes) that will be read and returned from the database table. The values contained in the movieID and title fields will be returned in this example.

8. Which three elements of a relational database are defined in the schema? (Choose three.)

  • attributes
  • aliases
  • relationships
  • SQL keywords
  • tables

Explanation: A schema is a formal description that describes the structure of the database and contains information about tables, attributes, and relationships.

 

 

Subscribe
Notify of
guest

0 Corrections & Clarifications