Podcast
Questions and Answers
What does DBMS stand for?
What does DBMS stand for?
Database Management System
What is the definition of data integrity?
What is the definition of data integrity?
Data integrity refers to the consistency of data in a database, ensuring adherence to defined rules to maintain accuracy and reliability.
Which of the following is NOT a potential advantage of using a database?
Which of the following is NOT a potential advantage of using a database?
What is a backup in the context of databases?
What is a backup in the context of databases?
Signup and view all the answers
What does the term "concurrent" refer to in database management?
What does the term "concurrent" refer to in database management?
Signup and view all the answers
What is meant by "data security" in database management?
What is meant by "data security" in database management?
Signup and view all the answers
In a database system, what is a query?
In a database system, what is a query?
Signup and view all the answers
Who are naive users in the context of database management?
Who are naive users in the context of database management?
Signup and view all the answers
It is typically the responsibility of the database administrator to write commands for creating a database structure.
It is typically the responsibility of the database administrator to write commands for creating a database structure.
Signup and view all the answers
What is data consistency?
What is data consistency?
Signup and view all the answers
Which level of the three-level database architecture contains user views?
Which level of the three-level database architecture contains user views?
Signup and view all the answers
What is Data Manipulation Language (DML)?
What is Data Manipulation Language (DML)?
Signup and view all the answers
What are the two essential parts of a data sublanguage?
What are the two essential parts of a data sublanguage?
Signup and view all the answers
Give an example of data rather than information.
Give an example of data rather than information.
Signup and view all the answers
On the logical level of the database, what is metadata?
On the logical level of the database, what is metadata?
Signup and view all the answers
Which of the following can be an entity?
Which of the following can be an entity?
Signup and view all the answers
Which of the following can be an attribute?
Which of the following can be an attribute?
Signup and view all the answers
In an ER diagram, what participation constraint is indicated by a single line between an entity set rectangle and a relationship diamond?
In an ER diagram, what participation constraint is indicated by a single line between an entity set rectangle and a relationship diamond?
Signup and view all the answers
No two attributes in a relationship can share a domain.
No two attributes in a relationship can share a domain.
Signup and view all the answers
In the ER model, what symbol is used to represent an attribute that can have multiple values for an entity instance?
In the ER model, what symbol is used to represent an attribute that can have multiple values for an entity instance?
Signup and view all the answers
A primary key can consist of more than one attribute.
A primary key can consist of more than one attribute.
Signup and view all the answers
The basic objects in the ER model include all of the following EXCEPT:
The basic objects in the ER model include all of the following EXCEPT:
Signup and view all the answers
In the ER model, a dashed oval is used to indicate which kind of attribute?
In the ER model, a dashed oval is used to indicate which kind of attribute?
Signup and view all the answers
A relationship set cannot have attributes of its own.
A relationship set cannot have attributes of its own.
Signup and view all the answers
Which data model level does an ER diagram best describe?
Which data model level does an ER diagram best describe?
Signup and view all the answers
On an ER diagram, how is the primary key of an entity indicated?
On an ER diagram, how is the primary key of an entity indicated?
Signup and view all the answers
In the ER model, what is a composite attribute?
In the ER model, what is a composite attribute?
Signup and view all the answers
What is a superkey in the context of the ER model?
What is a superkey in the context of the ER model?
Signup and view all the answers
In the ER model, what is a binary relationship?
In the ER model, what is a binary relationship?
Signup and view all the answers
What type of model is the ER model classified as?
What type of model is the ER model classified as?
Signup and view all the answers
In the ER model, what is the set of values permitted for an attribute called?
In the ER model, what is the set of values permitted for an attribute called?
Signup and view all the answers
In a bank, if savings accounts can be jointly owned by multiple customers, and customers can have multiple savings accounts, what type of relationship exists between the SavingsAccounts entity set and the Customer entity set?
In a bank, if savings accounts can be jointly owned by multiple customers, and customers can have multiple savings accounts, what type of relationship exists between the SavingsAccounts entity set and the Customer entity set?
Signup and view all the answers
In a university, students can get at most one parking permit for one car. Not all students have cars, and no car is allowed on campus without a permit. What is the participation constraint for the "Car" entity in the relationship to the "Student" entity?
In a university, students can get at most one parking permit for one car. Not all students have cars, and no car is allowed on campus without a permit. What is the participation constraint for the "Car" entity in the relationship to the "Student" entity?
Signup and view all the answers
In a business, if a department can have many workers, but each worker belongs to only one department, what is the cardinality of the department-to-worker relationship?
In a business, if a department can have many workers, but each worker belongs to only one department, what is the cardinality of the department-to-worker relationship?
Signup and view all the answers
In the ER model, what does cardinality refer to?
In the ER model, what does cardinality refer to?
Signup and view all the answers
A relationship in an ER diagram always connects two entity sets.
A relationship in an ER diagram always connects two entity sets.
Signup and view all the answers
In the relational model, the number of columns in a table corresponds to which property of a relation?
In the relational model, the number of columns in a table corresponds to which property of a relation?
Signup and view all the answers
What is referential integrity in the relational model?
What is referential integrity in the relational model?
Signup and view all the answers
If A and B are entity sets with a one-to-one relationship, which of the following is NOT true of the relational model representation?
If A and B are entity sets with a one-to-one relationship, which of the following is NOT true of the relational model representation?
Signup and view all the answers
In mapping a relationship to a relational schema, which of the following always requires a separate table?
In mapping a relationship to a relational schema, which of the following always requires a separate table?
Signup and view all the answers
Which of the following types of attributes can be directly represented as a column in a relational model?
Which of the following types of attributes can be directly represented as a column in a relational model?
Signup and view all the answers
What is a foreign key in the relational model?
What is a foreign key in the relational model?
Signup and view all the answers
In converting from an ER diagram to a relational model, what do tables represent?
In converting from an ER diagram to a relational model, what do tables represent?
Signup and view all the answers
What property must a superkey have to be a candidate key?
What property must a superkey have to be a candidate key?
Signup and view all the answers
If S = {a,b} and T = {1,2,3}, then how many ordered pairs are in the Cartesian product S × T?
If S = {a,b} and T = {1,2,3}, then how many ordered pairs are in the Cartesian product S × T?
Signup and view all the answers
The attributes of a relation are represented in a table by what?
The attributes of a relation are represented in a table by what?
Signup and view all the answers
In the relational model, what does referential integrity place restrictions on?
In the relational model, what does referential integrity place restrictions on?
Signup and view all the answers
What is the customary way to indicate a primary key in a relation schema?
What is the customary way to indicate a primary key in a relation schema?
Signup and view all the answers
What is the entity integrity constraint in the relational model?
What is the entity integrity constraint in the relational model?
Signup and view all the answers
In the relational model, what is the relation schema?
In the relational model, what is the relation schema?
Signup and view all the answers
The degree of a relation is a characteristic of the intention of the relation.
The degree of a relation is a characteristic of the intention of the relation.
Signup and view all the answers
Every relation in a relational database schema must have a foreign key.
Every relation in a relational database schema must have a foreign key.
Signup and view all the answers
If S = {a,b} and T = {1,2,3}, which of the following can be a relation for S × T?
If S = {a,b} and T = {1,2,3}, which of the following can be a relation for S × T?
Signup and view all the answers
All of the following are characteristics of relations in the relational model EXCEPT:
All of the following are characteristics of relations in the relational model EXCEPT:
Signup and view all the answers
All of the following are examples of constraints on relations in the relational model EXCEPT:
All of the following are examples of constraints on relations in the relational model EXCEPT:
Signup and view all the answers
What is the best method for representing a weak entity in a relational schema?
What is the best method for representing a weak entity in a relational schema?
Signup and view all the answers
The SQL option HAVING can only be used with which other option?
The SQL option HAVING can only be used with which other option?
Signup and view all the answers
To eliminate duplicates in the results of an SQL query, use which option?
To eliminate duplicates in the results of an SQL query, use which option?
Signup and view all the answers
What is the proper way to create an alias, E, for relational table EMPLOYEE and retrieve all employee data?
What is the proper way to create an alias, E, for relational table EMPLOYEE and retrieve all employee data?
Signup and view all the answers
Which SQL function returns the number of values in a column?
Which SQL function returns the number of values in a column?
Signup and view all the answers
If NAME contains character string data, what SQL SELECT specification should be used with WHERE NAME LIKE ___________ to retrieve only records where NAME begins with M and ends with 'ton'?
If NAME contains character string data, what SQL SELECT specification should be used with WHERE NAME LIKE ___________ to retrieve only records where NAME begins with M and ends with 'ton'?
Signup and view all the answers
To display data retrieved using an SQL SELECT in ascending order, use which option?
To display data retrieved using an SQL SELECT in ascending order, use which option?
Signup and view all the answers
All of the following are SQL DDL commands EXCEPT:
All of the following are SQL DDL commands EXCEPT:
Signup and view all the answers
Which SQL predicate is used to find rows in the Employee table that have no value for rating?
Which SQL predicate is used to find rows in the Employee table that have no value for rating?
Signup and view all the answers
What specification in the SQL CREATE TABLE command enforces referential integrity?
What specification in the SQL CREATE TABLE command enforces referential integrity?
Signup and view all the answers
To retrieve all columns from table A in a SQL SELECT operation, what should the SELECT read?
To retrieve all columns from table A in a SQL SELECT operation, what should the SELECT read?
Signup and view all the answers
To delete all records from a table EMPLOYEE and destroy its structure, which command should be used?
To delete all records from a table EMPLOYEE and destroy its structure, which command should be used?
Signup and view all the answers
To insert a record into a table with an always IDENTITY column, should the column be included in the set of values for attributes?
To insert a record into a table with an always IDENTITY column, should the column be included in the set of values for attributes?
Signup and view all the answers
Given an Employee table with columns for salary and dept, how would you raise the salaries of all employees in the sales department by 10%?
Given an Employee table with columns for salary and dept, how would you raise the salaries of all employees in the sales department by 10%?
Signup and view all the answers
All relational database management systems support all features of the SQL standard.
All relational database management systems support all features of the SQL standard.
Signup and view all the answers
Study Notes
Database Management Systems (DBMS)
- DBMS is the software that manages a database.
- Data Integrity is the consistency rules a database must follow.
- A Backup is a copy of the database for disaster recovery.
- Concurrent access means multiple users can access the database simultaneously.
- Data Security protects the database from unauthorized access.
- A Query is a question posed to the database (e.g., "Find students in ENG210").
- Naive Users interact with the database through application programs.
- The Database Administrator (DBA) writes commands to create database structure.
- Data Consistency means all copies of the same data item agree.
- The External level in the database architecture contains user views.
- Data Manipulation Language (DML) retrieves data from a database.
- Data Definition Language (DDL) and Data Manipulation Language (DML) are the core parts of a data sublanguage.
- An unordered list of grades is data, not information.
- Metadata is data about data (at the logical level).
- An entity can be a vendor.
- StudentID can be an attribute.
- Partial participation in an ER diagram is indicated by a single line between entities and relationship.
- Two attributes in a relationship cannot share the same domain.
- A double oval in an ER model represents an attribute with multiple values for an entity.
- A primary key can have multiple attributes.
- Classes are not basic objects in the ER Model.
- A dashed oval in the ER model shows a derived attribute.
- A relationship can have its own attributes.
- The ER diagram describes the conceptual data model.
- A primary key in an ER diagram is underlined.
- A composite attribute is an attribute divided into smaller parts (e.g., address).
- A superkey uniquely identifies an entity instance.
- A binary relationship links two entity sets.
- The ER model is a semantic model.
- The domain is the set of valid values for an attribute.
- The relationship between Savings Accounts and Customers is many-to-many.
Relational Databases
- Entity Integrity: A primary key cannot contain null values.
- Referential Integrity: A foreign key must match a primary key or be null.
- A many-to-many relationship requires a separate table when mapping to relations (SQL).
- A single-valued, non-composite attribute maps directly to a relation column.
- A foreign key references a primary key in another table.
- Tables represent both entities and relationships when converting from ER diagrams.
- A candidate key is a superkey with no proper subset that is also a superkey.
- Cartesian product size calculation (example given using S={a, b} and T={1, 2, 3}).
- A relation's attributes are represented as columns in a table.
- Foreign keys are constrained by referential integrity.
- An SQL primary key is indicated by underlining.
- The schema is the structure of a relation, including attributes and domain information.
- Relation degree is the number of columns in a table, not a characteristic of the relation's intent.
- Relations do not always have foreign keys.
- A relation for a Cartesian product example is given (S×T).
- A relation's cells contain only one value.
- Boundary constraints are not constraints on relations.
- Represent a weak entity by creating tables for both the strong and weak entities, including the strong entity's primary key in the weak entity's table.
- HAVING can only be used with GROUP BY.
- DISTINCT removes duplicates in SQL queries.
-
SELECT * FROM EMPLOYEE E;
aliases EMPLOYEE as E and retrieves all its data. -
COUNT
returns the number of values in a column in SQL. -
'M%ton'
retrieves names beginning with M and ending with 'ton' in SQL. -
ORDER BY
sorts data in SQL.
SQL Commands
- SQL DDL commands are not ADD TABLE.
-
WHERE RATING IS NULL
retrieves rows with null ratings. - The
FOREIGN KEY
clause enforces referential integrity. -
SELECT * FROM A...
retrieves all columns from table A. -
DROP EMPLOYEE;
deletes a table (and all its data). -
WHERE RATING IS NULL
finds rows with null 'rating' values. - Always IDENTITY columns in SQL should not include columns in the set of values.
- The SQL command
UPDATE Employee SET salary = salary*1.10 WHERE dept='sales';
raises sales department salaries by 10%. - Not all relational database systems support all SQL standard features.
Studying That Suits You
Use AI to generate personalized quizzes and flashcards to suit your learning preferences.
Description
Test your knowledge on Database Management Systems (DBMS) with this quiz. Explore concepts such as data integrity, security, and the roles of database administrators. Perfect for anyone looking to solidify their understanding of database fundamentals.