Review For Final

¡Supera tus tareas y exámenes ahora con Quizwiz!

A person's name, birthday, and social security number are all examples of: A) attributes. B) entities. C) relationships. D) descriptors.

A

What does the following SQL command do? insert into Customer_T values (001,'John Smith','231 West St','Boston','MA','02115'); A) Adds a new record to the Customer_T B) Creates the Customer_T table C) Deletes the Customer_T table D) Updates the Customer_T table

A

What does the following SQL statement do? Delete from Customer_T where state = 'HI'; A) Deletes all records from customer_t where the state is equal to HI B) Removes the Customer_T table from the database C) Deletes all records from the Customer_T table D) None of the above

A

What will be returned when the following SQL query is executed? Select driver_no, count(*) as num_deliveries from deliveries group by driver_no having count(*) > 2; A) A listing of all drivers who made more than 2 deliveries as well as a count of the number of deliveries B) A listing of all drivers C) A listing of the number of deliveries greater than 2 D) A listing of all drivers who made more than 2 deliveries

A

________ use the result of the outer query to determine the processing of the inner query. A) Correlated subqueries B) Outer subqueries C) Inner subqueries D) Subqueries

A

crows feet

A "many" maximum cardinality noted on the E-R diagram

Explain what a candidate key is and how it might be used.

A candidate key is an attribute or a combination of attributes that uniquely identifies a row in a relation. A candidate key must be nonredundant and must also uniquely identify each row. When we look at functional dependencies and candidate keys, we can always say that a determinant is always a candidate key.

Entity Type

A collection of entities that share common properties or characteristics

security specifications

A form of database specification which maps conceptual requirements is called: A) logical specifications. B) response specifications. C) security specifications. D) physical specifications

false

A primary key should be null.

Attribute

A property or characteristic of an entity or relationship type that is of interest to the organization

Unary Relationship

A relationship between instances of a single entity type

Entity Instance

A single occurrence of an entity type

How do you convert weak entities to relations?

A weak entity becomes a relation. However, since a weak entity instance does not exist by itself, we must create a relation with the primary key from the strong relation as the primary key, as well as the identifying attribute.

Relationship Instance

An association between (or among) entity instances where each relationship instance associates exactly one entity instance from each participating entity type

Composite Attribute

An attribute that has meaningful component parts (attributes).

Mapping associative entities

Associative entities are mapped into relational database constructs in the identical way as M:N relationships

) An attribute that must have a value for every entity (or relationship) instance is a(n): A) composite attribute. B) required attribute. C) optional attribute. D) multivalued attribute.

B

A ________ is a temporary table used in the FROM clause of an SQL query. A) correlated subquery B) derived table C) view table D) none of the above

B

A ________ specifies the number of instances of one entity that can be associated with each instance of another entity. A) degree B) cardinality constraint C) counter constraint D) limit

B

In a SQL statement, which of the following parts states the conditions for row selection? A) From B)Where C)Select D)Group by

B

In order for two queries to be UNION-compatible, they must: A) both have the same number of lines in their SQL statements. B) both output compatible data types for each column and return the same number of rows. C) both return at least one row. D) all of the above.

B

While triggers run automatically, ________ do not and have to be called. A) trapdoors B) routines C) selects D) updates

B

SQL-invoked routines can be: A) procedures. B) functions. C) all of the above. D) none of the above.

C

The SQL command ________ defines a logical table from one or more tables or views. A) create table B) alter table C) create view D) create relationship

C

data governance can be defined as: A)a government task force for defining data quality B)a means to slow down the speed of data C)high level organizational groups and processes that oversee data stewardship D)none of the above

C

true

Cardinality is the number of instances of entity B that can (or must) be associated with each instance of entity A.

false

During systems design, a conceptual data model with attributes is prepared.

A catalog is the structure that contains object descriptions created by a user.

False

A database is maintained and queried using the data mapping language (DML).

False

Persistent Sorted Modules are extensions defined in SQL-99 that include the capability to create and drop modules of code stored in the database schema across user sessions.

False

SQL originated from a project called System-S.

False

The following command would work fine: insert into budget values 121,222,111;

False

The following query totals sales in state= 'MA' for each salesperson. Select salesperson_id, sum(sales) from salesperson group by salesperson_id having state = 'MA';

False

The natural join is very rarely used (T/F)

False

User-defined functions can improve system performance because they will be processed as sets rather than individually, thus reducing system overhead.

False

Using an outer join produces this information: rows that do not have matching values in common columns are not included in the result table.

False

underlined

On an entity-relationship diagram, the entity's identifier is:

false

Social security number, last name, and first name are examples of entity types.

True

T/F A good data definition is always accompanied by diagrams, such as the entity-relationship diagram

True

T/F A multivalued attribute may take on more thank once value for a particular entity instance

True

T/F A single occurrence of an entity is called an entity instance

True

T/F In an E-R diagram, an associative entity is represented by a rounded rectangle

False

T/F In an E-R diagram, strong entities are represented by double-walled rectangles

False

T/F The purpose of data modeling is to document business rules about processes

False

T/F The relationship among the instances of three entity types is called a unary relationship

Identifying Relationship

The relationship between a weak entity type and its owner

A correlated subquery is executed once for each iteration through the outer loop.

True

A database table is defined using the data definition language (DDL).

True

A join in which the joining condition is based on equality between values in the common column is called a(n) equi-join.

True

A major benefit of SQL as a standard is reduced training costs

True

A natural join is the same as an equi-join, except that it is performed over matching columns that have been defined with the same name, and one of the duplicate columns is eliminated (T/F)

True

A procedure is run by calling it by its name.

True

Applications can be moved from one machine to another when each machine uses SQL

True

Constraints are a special case of triggers.

True

Correlated subqueries are less efficient than queries that do not use nesting.

True

Establishing IF-THEN-ELSE logical processing within an SQL statement can now be accomplished by using the CASE keyword in a statement.

True

SQL statements can be included in another language, such as C or Java.

True

The SQL command used to populate tables is the INSERT command.

True

The content of dynamic views is generated when they are referenced

True

synonyms

Two or more attributes having different names but the same meaning are called: A) homonyms. B) aliases. C) synonyms. D) alternate attributes.

An anomaly is an error or inconsistency that may result when a user attempts to update a table that contains redundant data. There are three types of anomalies. An insert anomaly occurs when a user attempts to enter new information for part of a table. For example, if we stored customer address with an order. A deletion anomaly occurs when the user wants to delete part of a record but also has to delete related data. A modification anomaly occurs when we have to change the same data in multiple places

What is an anomaly, and what are the three types of anomalies?

Sam Hinz

Which of the following violates the atomic property of relations? A) Sam B) Hinz C) Sam Hinz D) Atomic

entity instance

a single occurance of an entity type

The normal form which removes any remaining functional dependencies because there was more than one primary key for the same nonkeys is called: A) fifth normal form. B) fourth normal form. C) Boyce-Codd normal form. D) sixth normal form.

boyce-codd normal form

Foreign key

column in a relation that refers to a primary key column in another (referred) relation

A primary key that consists of more than one attribute is called a: A) foreign key. B) composite key. C) multivalued key. D) cardinal key.

composite key

In the SQL language, the ________ statement is used to make table definitions. A) create session B) create table C) create index D) select

create table

________ problems are encountered when removing data with transitive dependencies. A) Insertion B) Modification C) Deletion D) Merging

deletion

A composite key consists of only one attribute.

false

Unlike columns, the rows of a relation may not be interchanged and must be stored in one sequence.

false

When transforming a unary many-to-many relationship to relations, a recursive foreign key is used.

false

database

final

A domain definition consists of all of the following components EXCEPT: A) domain name. B) data type. C) integrity constraints. D) size.

integrity constraints

Relational database model

logical database model that represents a database as a collection of related tables

A functional dependency in which one or more nonkey attributes are functionally dependent on part, but not all, of the primary key is called a ________ dependency. A) partial key-based B) partial functional C) cross key D) merged relation

partial function

Relational database constraints

rules that a relational database has to satisfy in order to be valid

data

the most complex aspects of many modern information systems is what?

) A simultaneous relationship among the instances of three entity types is called a(n) ________ relationship. A) ternary B) tertiary C) primary D) binary

A

Dynamic SQL: A) is used to generate appropriate SQL code on the fly as an application is processing. B) is quite volatile. C) is not used widely on the Internet. D) creates a less flexible application

A

In an E-R diagram, there are ________ business rule(s) for every relationship. A) two B) three C) one D) none

A

true

A faculty identification number could be used as an identifier.

homonym

An attribute that may have more than one meaning is called a(n): A) homonym. B) alias. C) double defined attribute. D) synonym.

A type of join where a table is joined to itself is called a(n): A) unary join. B) self-join. C) unnatural join. D) pinned join.

B

All of the following are part of the coding structure for triggers EXCEPT: A) event. B) condition. C) selection. D) action.

C

Loading data into a data warehouse involves: A)updating existing rows with new data B)purging data that have become obsolete or were incorrectly loaded C)appending new rows to the tables in the warehouse D)all of the above

D

User-defined constraints

Database constraints that are added by the database designer

Strong entity/weak entity

In the figure below, what type of relationship do the relations depict? A) Strong entity/weak entity B) Multivalued C) Composite foreign key D) One-to-many

one-to-Many

In the figure below, what type of relationship do the relations depict? A) Strong entity/weak entity B) One-to-many C) Ternary D) Many-to-many

false

Processes, rather than data, are the most complex aspects of many modern information systems.

true

Referencing an employee entity, an employee's skills are an example of a multivalued attribute.

Expressions are mathematical manipulations of data in a table that may be included as part of the SELECT statement.

True

The ORDER BY clause sorts the final results rows in ascending or descending order.

True

identifier

a faculty ID number could be used as what?

A view may not be updated directly if it contains: A) the DISTINCT keyword. B) derived columns and expressions in the SELECT clause. C) uses the GROUP BY or HAVING clause. D) all of the above.

D

All of the following are advantages of SQL-invoked routines EXCEPT: A) flexibility. B) efficiency. C) sharability. D) security.

D

An attribute that can be calculated from related attribute values is called a(n) ________ attribute. A) simple B) composite C) multivalued D) derived

D

One major disadvantage of the outer join is that information is easily lost.

False

There is a special operation in SQL to join a table to itself.

False

When the SELECT clause in the create view statement contains the keyword DISTINCT, the view can be used to update data.

False

false

Use a verb or verb phrase to name an entity.

When creating a table, it is not important to consider foreign key—primary key mates.

False

When transforming a one-to-one relationship, a new relation is always created.

galse

First normal form

When all multivalued attributes have been removed from a relation, it is said to be in: A) first normal form. B) second normal form. C) Boyce-Codd normal form. D) third normal form

Identifier

An attribute (or combination of attributes) whose value distinguishes instances of an entity type

Natural join

An equi-join in which one of the duplicate columns is eliminated in the result table

The following queries produce the same results. select customer_name, customer_city from customer, salesman where customer.salesman_id = salesman.salesman_id and salesman.lname = 'SMITH'; select customer_name, customer_city from customer where customer.salesman_id = (select salesman_id from salesman where lname = 'SMITH');

True

The following query totals sales for each salesperson. Select salesperson_id, sum(sales) from salesperson group by salesperson_id;

True

A candidate key is an attribute, or combination of attributes, that uniquely identifies a row in a relation.

true

A cascading delete removes all records in other tables associated with the record to be deleted.

true

A business rule: A) defines or constrains some aspect of the business. B) asserts business structure. C) controls or influences the behavior of the business. D) all of the above.

D

A good data definition will all of the characteristics of a data object EXCEPT: A) subtleties. B) examples. C) who determines the value of the data. D) who can delete the data.

D

Specifying the attribute names in the SELECT statement will make it easier to find errors in queries and also correct for problems that may occur in the base system.

False

Subqueries can only be used in the WHERE clause.

False

The DROP command deletes rows from a table individually or in groups.

False

The HAVING clause and the WHERE clause perform the same operation.

False

The ORDER BY clause is the first statement processed in an SQL command.

False

The comparison operators = and != are used to establish a range of values.

False

Two or more attributes having different names but the same meaning are called: A) homonyms. B) aliases. C) synonyms. D) alternate attributes.

synonyms

Relation

table in a relational database: A table containing rows and columns, The main construct in the relational database model, Every relation is a table, not every table is a relation

true

The top-down approach to data modeling derives a data model from an intimate understanding of the nature of the business.

One of the original purposes of the SQL standard was to provide a vehicle for portability of database definition and application modules between conforming DBMSs.

True

Persistent Stored Modules are extensions defined in SQL:1999 that include the capability to add and drop modules of code.

True

RDBMSs store database definition information in system-created tables which can be considered a data dictionary.

True

SQL is both an American and international standard for database access.

True

SQL:2008 allows one to calculate linear regressions, moving averages and correlations without moving the data outside of the database.

True

Some DBMS can handle graphic data types as well as text and numbers.

True

The ALTER TABLE command is used to change a table definition.

True

The joining condition of an equi-join is based upon an equality.

True

The views are created by executing a CREATE VIEW SQL command.

True

Triggers have three parts: the event, the condition, and the action.

True

When EXISTS or NOT EXISTS is used in a subquery, the select list of the subquery will usually just select all columns as a placeholder because it doesn't matter which columns are returned.

True

When a GROUP BY clause is included in an SQL statement, only those columns with a single value for each group can be included.

True

When creating tables, it's important to decide which columns will allow null values before the table is created.

True

Mapping unary relationships

Unary relationships in ER diagrams are mapped in the same way as binary relationships

Relational database

collection of related relations within which each relation has a unique name

Primary key

column (or a set of columns) whose value is unique for each row, Each relation must have a primary key, The name of the primary key column is underlined in order to distinguish it from the other columns in the relation

The entity integrity rule states that: A) no primary key attribute can be null. B) referential integrity must be maintained across all entities. C) each entity must have a primary key. D) a primary key must have only one attribute.

no primary key attribute can be null

Which of the following are properties of relations? A) Each attribute has the same name. B) No two rows in a relation are identical. C) There are multivalued attributes in a relation. D) All columns are numeric.

no two rows in a relation are identical

primary key

what should never be null?

The WHERE clause is always processed before the GROUP BY clause when both occur in a SELECT statement.

True

DCL is used to update the database with new records.

False

a representation of organizational data

What is conceptual data modeling?

It is better not to have a result set identified before writing GROUP BY and HAVING clauses for a query.

False

MULTISET is similar to the table datatype.

False

Materialized views are stored on disk and are never refreshed.

False

The CREATE SCHEMA DDL command is used to create a table.

False

Implementation of a standard can never stifle creativity and innovation.

False

Indexes generally slow down access speed in most RDMS.

False

In order to update data in SQL, one must inform the DBMS which relation, columns, and rows are involved.

True

Customers, cars, and parts are examples of: A) entities. B) attributes. C) cardinals. D) relationships.

A

instances

A data entity will have many possible

descriptor

A nonkey attribute is also called a(n): A) column. B) unimportant datum. C) descriptor. D) address.

Ternary Relationship

A simultaneous relationship among the instances of three entity types

primary key

An attribute (or attributes) that uniquely identifies each row in a relation is called a: A) column. B) foreign field. C) primary key. D) duplicate key.

Composite Identifier

An identifier that consists of a composite attribute

true

An order number is a good example of a candidate key.

An interactive command that can be used to dynamically control a user session for appropriate integrity measures is: A) rollback. B) rollforward. C) set autocommit. D) expunge.

C

All of the following are new data types added in SQL:200n Except: BIGINT. BIT. MULTISET. XML.

BIT.

) Which of the following is NOT a characteristic of a good business rule? A) Declarative B) Atomic C) Inconsistent D) Expressible

C

The union clause is used to

Combine the output from multiple queries into a single result table

There are six different normal forms, all of which build upon each other. When a relation is in first normal form, all repeating groups have been removed. Second normal form means that any partial functional dependencies have been removed. A partial functional dependency occurs when a primary key is a composite key and a nonkey attribute is dependent upon part of the key. A relation is in third normal form when all transitive dependencies have been resolved. A transitive dependency occurs when one nonkey attribute is dependent upon another nonkey attribute. Boyce-Codd normal form removes any further dependencies that may result from anomalies. A relation is in fourth normal form when any dependencies from multivalued attributes have been removed. Fifth normal form removes any further anomalies. LO: 4.8: Use normalization to decompose a relation with anomalies into well-structured

List and explain 1st, 2nd, 3rd, BCNF, 4th, and 5th normal forms

Mapping 1:1 unary relationships

Mapped in the same way as 1:M unary relationships

Mapping entities with optional attributes into relations

Optional attribute of an entity is mapped as an optional column

true

Relationships are labeled with verb phrases.

Joining tables or using a subquery may produce the same result.

True

False

T/F A Cardinality constraint tells what kinds of properties are associated with an entity

True

T/F Data names should always relate to business characteristics

entity integrity rule

The ________ states that no primary key attribute may be null. A) referential integrity constraint B) entity integrity rule C) partial specialization rule D) range domain rule

determinant.

The attribute on the left-hand side of the arrow in a functional dependency is the: A) candidate key. B) determinant. C) foreign key. D) primary key.

true

The bottom-up approach to data modeling derives a data model by reviewing specific business documents.

no primary key attribute can be null.

The entity integrity rule states that: A) no primary key attribute can be null. B) referential integrity must be maintained across all entities. C) each entity must have a primary key. D) a primary key must have only one attribute

Discuss how to map a unary one-to-many relationship.

The entity type in the unary relationship is mapped to a relation in the same way as we did for a relation. We next add a foreign key attribute, which maps back to the primary key. This is called a recursive foreign key. So, if we had a relation such as a person supervises one or more persons, the person_id would be a primary key and then there would be a supervisor id which points back to the person_id.

Implicit constraints

The implicit relational database model rules that a relational database must satisfy in order to be valid

List and explain 1st, 2nd, 3rd, BCNF, 4th, and 5th normal forms.

There are six different normal forms, all of which build upon each other. When a relation is in first normal form, all repeating groups have been removed. Second normal form means that any partial functional dependencies have been removed. A partial functional dependency occurs when a primary key is a composite key and a nonkey attribute is dependent upon part of the key. A relation is in third normal form when all transitive dependencies have been resolved. A transitive dependency occurs when one nonkey attribute is dependent upon another nonkey attribute. Boyce-Codd normal form removes any further dependencies that may result from anomalies. A relation is in fourth normal form when any dependencies from multivalued attributes have been removed. Fifth normal form removes any further anomalies.

) The following two SQL statements will produce the same results. Select last_name, first_name from customer where credit_limit > 99 and credit_limit < 10001; Select last_name, first_name from customer where credit_limit between 100 and 10000;

True

A natural join is the same as an equi-join, except that it is performed over matching columns that have been defined with the same name, and one of the duplicate columns is eliminated.

True

A trigger is a named set of SQL statements that are considered when a data modification occurs.

True

systems analysis stage of SDLC

When does conceptual data modeling occur?

Explain how subtype/supertype relationships are converted to relations.

When we have a supertype/subtype relationship, we need to assign one entity for the supertype and one for each subtype. The supertype has all attributes common to all subtypes as well as a primary key. Each subtype relation has the primary key of the supertype as well as any attributes that are specific to that subtype. Finally, we assign one or more attributes to the supertype to function as subtype discriminators.

entity

a person, place, object, event or concept in the user environment about which the organization wishes to maintain data

Composite primary key

a primary key that is composed of multiple columns

Modification

________ are anomalies that can be caused by editing data in tables. A) Insertion B) Deletion C) Modification D) Creation

Physical

________ database specification indicates all the parameters for data storage that are then input to database implementation. A) Logical B) Physical C) Schematic D) Conceptual

Data integrity

________ is a component of the relational data model included to specify business rules to maintain the integrity of data when they are manipulated. A) Business rule constraint B) Data integrity C) Business integrity D) Data structure

Deletion

________ problems are encountered when removing data with transitive dependencies. A) Insertion B) Modification C) Deletion D) Merging

identifier

a candidate key that has been selected as the unique identifying characteristic for an entity type

entity type

a collection of entities that share common properties or characteristics

conceptual data model

a detailed model that shows the overall structure of organizational data while being independent of any database management system or other implementation considerations

ER diagram

a graphical representation of the entities, associations, and data for an organization or business area; it is a model of entities, the associations among those entities, and the attributes of both the entities and their associatio

An alternative name for an attribute is called a(n): A) synonym. B) alias. C) alternate attribute. D) related characteristic.

alias

relationship

an asociation between he instances of one or more entity types that is of interest to the organization

candidate key

an attribute (or combination of attributes) that uniquely identifies each instance of an entity type

When a regular entity type contains a multivalued attribute, one must: A) create a single relation with multiple lines for each instance of the multivalued attribute. B) create two new relations, one containing the multivalued attribute. C) create two new relations, both containing the multivalued attribute. D) delete the relation and start over.

create two new relations, one containing the multivalued attribute

Primary key Constraint

each relation must have a primary key, which is a column (or a set of columns) whose value is unique for each row

Autonumber data type option

enables automatic generation of consecutive numeric data values in a column

62) When transforming a weak entity, one should create one relation with both the attributes of the strong entity and the attributes of the weak entity.

false

A co-dependency is a constraint between two attributes or two sets of attributes.

false

A foreign key is a primary key of a relation that also is a primary key in another relation.

false

A relation is in first normal form if it has no more than one multivalued attribute.

false

Entity integrity constraint

in a relational table, no primary key column can have null (empty) values

All of the following are the main goals of normalization EXCEPT: A) minimize data redundancy. B) simplify the enforcement of referential integrity. C) maximize storage space. D) make it easier to maintain data.

maximize storage space

________ database specification indicates all the parameters for data storage that are then input to database implementation. A) Logical B) Physical C) Schematic D) Conceptual

physical

An attribute (or attributes) that uniquely identifies each row in a relation is called a: A) column. B) foreign field. C) primary key. D) duplicate key.

primary key

A rule that states that each foreign key value must match a primary key value in the other relation is called the: A) referential integrity constraint. B) key match rule. C) entity key group rule. D) foreign/primary match rule.

referential integrity constraint

A relation that contains no multivalued attributes and has nonkey attributes solely dependent on the primary key but contains transitive dependencies is in which normal form? A) First B) Second C) Third D) Fourth

second

A primary key is an attribute that uniquely identifies each row in a relation.

true

Sample data are useful for developing prototype applications and for testing queries.

true

When a regular entity type contains a multivalued attribute, two new relations are created.

true

When normalizing, the goal is to decompose relations with anomalies to produce smaller, well-structured relations.

true

When two or more attributes describe the same characteristic of an entity, they are synonyms.

true

) Data modeling may be the most important part of the systems development process because: A) data characteristics are important in the design of programs and other systems components. B) the data in a system are generally less complex than processes and play a central role in development. C) data are less stable than processes. D) it is the easiest.

A

A property or characteristic of an entity type that is of interest to the organization is called a(n): A) attribute. B) coexisting entity. C) relationship. D) cross-function.

A

An entity that associates the instances of one or more entity types and contains attributes specific to the relationships is called a(n): A) associative entity. B) connecting entity. C) intersectional entity. D) all of the above.

A

Embedded SQL consists of: A) hard-coded SQL statements included in a program written in another language. B) SQL encapsulated inside of other SQL statements. C) SQL written into a front-end application. D) SQL translated to a lower-level language.

A

In SQL, a(n) ________ subquery is a type of subquery in which processing the inner query depends on data from the outer query. A) correlated B) paired C) natural D) inner

A

Multiple values returned from an SQL query that includes an aggregate function are called: A) vector aggregates. B) scalar aggregates. C) agates. D) summations

A

The MERGE command: A) allows one to combine the INSERT and UPDATE operations. B) allows one to combine the INSERT and DELETE operations. C) joins 2 tables together. D) none of the above.

A

The UNION clause is used to: A) combine the output from multiple queries into a single result table. B) join two tables together to form one table. C) find all rows that do not match in two tables. D) none of the above.

A

The ________ DBA view shows information about all users of the database in Oracle. A) DBA_USERS B) USERS C) DBA_VIEWS D) DBA_INDEXES

A

The outer join syntax does not apply easily to a join condition of more than ________ tables. A) two B) three C) four D) any number of

A

The total quiz points for a student for an entire semester is a(n) ________ attribute. A) derived B) mixed C) stored D) addressed

A

To get all the customers from Hawaii sorted together, which of the following would be used? A)order by B)having C)group by D)sort

A

To get all the customers from Hawaii sorted together, which of the following would be used? A) ORDER BY B) GROUP BY C) HAVING D) SORT

A

User-defined transactions can improve system performance because: A) transactions are processed as sets, reducing system overhead. B) transactions are mapped to SQL statements. C) speed is improved due to query optimization. D) all of the above.

A

What does the following SQL statement do? Select * From Customer Where Cust_Type = "Best" A) Selects all the fields from the Customer table for each row with a customer labeled "Best" B) Selects the "*" field from the Customer table for each row with a customer labeled "Best" C) Selects fields with a "*" in them from the Customer table D) Selects all the fields from the Customer table for each row with a customer labeled "*"

A

What results will be produced by the following SQL query? Select sum(standard_price) as Total_Price from Product_V where Product_Type = 'WOOD'; A) The total price of all products that are of type wood B) The total price of all products C) The Standard_Price of the first wood product in the table D) The Standard_Price of any wood product in the table

A

Which of the following counts ONLY rows that contain a value? A) Count B) Count(*) C) Tally(*) D) Checknum

A

Which of the following is the wildcard operator in SQL statements? A) * B) & C) = D) <>

A

Which of the following questions is answered by the SQL statement? Select Count(Product_Description) from Product_T A)how many products have product descriptions in the product table? B)how many different columns named "product_description" are there in the table Product_T? C)How many products are in the table Product_T?

A

Which of the following terms best describes a class of tools used by end users to analyze data in a data warehouse? A)OLAP B)Data Mart C)DBMS D)CUBE

A

________ is a set of commands used to update and query a database. A) DML B) DDL C) DCL D) DPL

A

_______takes a value of true if a subquery returns an intermediate results table which contains one or more rows A)Exists B)Having C)In D)Extents

A

the key must indicate the row's position in the table

A candidate key must satisfy all of the following conditions EXCEPT: A) the key must uniquely identify the row. B) the key must indicate the row's position in the table. C) the key must be nonredundant. D) each nonkey attribute is functionally dependent upon it.

functional dependency

A constraint between two attributes is called a(n): A) functional relation. B) attribute dependency. C) functional dependency. D) functional relation constraint

integrity constraints.

A domain definition consists of all of the following components EXCEPT: A) domain name. B) data type. C) integrity constraints. D) size.

transitive dependency.

A functional dependency between two or more nonkey attributes is called a: A) partial functional dependency. B) partial nonkey dependency. C) transitive dependency. D) partial transitive dependency.

partial functional

A functional dependency in which one or more nonkey attributes are functionally dependent on part, but not all, of the primary key is called a ________ dependency. A) partial key-based B) partial functional C) cross key D) merged relation

Entity-Relationship Diagram (E-R Diagram)

A graphical representation of an entity-relationship model

Outer join

A join in which rows that do not have matching values in common columns are nonetheless included in the result table (As opposed to inner join, in which rows must have matching values in order to appear in the result table)

Equi-join

A join in which the joining condition is based on equality between values in the common columns; common columns appear redundantly in the result table

What will be returned even the following SQL query is executed? Select driver_no, count(*) as num_deliveries From deliveries Group by driver_no having count(*) > 2

A listing of all drivers who made more than 2 deliveries as well as a count of the number of deliveries

Entity-Relationship Model (E-R Model)

A logical representation of the data for an organization or for a business area, using entities for categories of data and relationships for associations between entities.

Relationship Type

A meaningful association between (or among) entity types

true

A multivalued attribute is an attribute that may take on more than one value for each entity instance.

Discuss why it is important to remove multivalued attributes from a relation.

A multivalued attribute is one that can take on more than one value. According to the definition of a relation, there can be no multivalued attributes. The reason for this will be seen later when the schema is normalized. A multivalued attribute can be resolved by creating a separate instance for each value and repeating the data from the non-multivalued attributes.

Entity

A person, a place, an object, an event, or a concept in the user environment about which the organization wishes to maintain data

Composite Key

A primary key that consists of MORE THAN ONE ATTRIBUTE IS CALLED A: A) foreign key. B) composite key. C) multivalued key. D) cardinal key.

Discuss the various relational keys.

A primary key uniquely identifies each row of a relation (or table). It can be either a single column or a composite of two or more columns, which is called a composite key. A foreign key allows us to represent the relationship between two tables. A foreign key in one table is generally a reference to a primary key in another table.

Enterprise Key

A primary key whose value is unique across all relations is called a(n): A) global primary key. B) inter-table primary key. C) enterprise key. D) foreign global key

well-structured

A relation that contains minimal redundancy and allows easy use is considered to be: A) clean. B) simple. C) complex. D) well-structured

Second

A relation that contains no multivalued attributes and has nonkey attributes solely dependent on the primary key but contains transitive dependencies is in which normal form? A) First B) Second C) Third D) Fourth

Join

A relational operation that causes two or more tables with a common domain to be combined into a single table or view (The common columns in joined tables are usually the primary key in the dominant table and the foreign key of the dependent table)

Binary Relationship

A relationship between the instances of two entity types

Cardinality Constraint

A rule that specifies the number of instances of one entity that can (or must) be associated with each instance of another entity.

referential integrity constraint.

A rule that states that each foreign key value must match a primary key value in the other relation is called the: A) referential integrity constraint. B) key match rule. C) entity key group rule. D) foreign/primary match rule.

Business Rule

A statement that defines or constrains some aspect of the business. It is intended to assert business structure or to control or include certain the behavior of the business

Discuss when it is best to create a surrogate key for an associative entity.

A surrogate key should be created when any of the following conditions hold: there is a composite primary key, the natural primary key is inefficient (such as a long name) or the natural primary key is recycled. When you have an associative entity, it is often best to use a surrogate key when you have more than two relations that the associative entity is related to, since the primary key would be a composite of the primary keys of all entities related to the associative entity.

false

A ternary relationship is the equivalent of three binary relationships.

Time Stamp

A time value that is associated with a data value, often indicating when some event occurred that affected the data value

Relation

A two-dimensional table of data sometimes is called a: A) group. B) set. C) declaration. D) relation.

User-defined constraints

Added by the database designers

Maximize Storage Pace

All of the following are the main goals of normalization EXCEPT: A) minimize data redundancy. B) simplify the enforcement of referential integrity. C) maximize storage space. D) make it easier to maintain data

alias.

An alternative name for an attribute is called a(n): A) synonym. B) alias. C) alternate attribute. D) related characteristic

What is an anomaly, and what are the three types of anomalies?

An anomaly is an error or inconsistency that may result when a user attempts to update a table that contains redundant data. There are three types of anomalies. An insert anomaly occurs when a user attempts to enter new information for part of a table. For example, if we stored customer address with an order. A deletion anomaly occurs when the user wants to delete part of a record but also has to delete related data. A modification anomaly occurs when we have to change the same data in multiple places.

Foreign Key

An attribute in a relation of a database that serves as the primary key of another relation in the same database is called a: A) link attribute. B) link key. C) foreign key. D) foreign attribute.

Simple (or atomic) attribute

An attribute that cannot be broken down into smaller components that are meaningful to the organization

Optional Attribute

An attribute that may not have a value for every entity (or relationship) instance with which it is associated

Multivalued attribute

An attribute that may take on more than one value for a given entity (or relationship) instance

Required Attribute

An attribute that must have a volume for every entity (or relationship) instance with which it is associated

Derived Attribute

An attribute whose values can be calculated from related attribute values

Mapping entities with multivalued attributes into relational database constructs

An entity containing the multivalued attribute is mapped without the multi-valued attribute, The multi-valued attribute is mapped as a separate relation that has a column representing the multivalued attribute and a foreign key column referring to the primary key of the relation resulting from the entity itself Both of these columns form a composite primary key for the separate relation

true

An entity instance is a single occurrence of an entity type.

true

An entity is a person, place, object, event, or concept in the user environment about which the organization wishes to maintain data.

Strong Entity Type

An entity that exists independently of other entity types

Associative Entity

An entity type that associates the instances of one or more entity types and contains attributes that are peculiar to the relationship between those entity instances

Weak Entity Type

An entity type whose existence depends on some other entity type

Mapping entities with unique composite attributes into relations

An entity whose only unique attribute is a composite attribute is mapped as a relation with a composite primary key

A ________ view is materialized when referenced. A) virtual B) dynamic C) materialized D) base

B

A fact is an association between two or more: A) words. B) terms. C) facts. D) nuggets.

B

A join operation: A) brings together data from two different fields. B) causes two tables with a common domain to be combined into a single table or view. C) causes two disparate tables to be combined into a single table or view. D) is used to combine indexing operations.

B

A join that is based upon equality between values in two common columns with the same name and where one duplicate column has been removed is called a(n): A) equi-join. B) natural join. C) multivariate join. D) inner join

B

A mutually exclusive relationship is one in which: A) an entity instance can participate in many different relationships. B) an entity instance can participate in only one of several alternative relationships. C) an entity instance can not participate in a relationship with another entity instance. D) none of the above.

B

A single value returned from an SQL query that includes an aggregate function is called a(n): A) agate. B) scalar aggregate. C) vector aggregate. D) summation.

B

A student can attend five classes, each with a different professor. Each professor has 30 students. The relationship of students to professors is a ________ relationship. A) one-to-one B) many-to-many C) one-to-many D) strong

B

A type of query that is placed within a WHERE or HAVING clause of another query is called a: A) master query. B) subquery. C) superquery. D) multi-query

B

A value that indicates the date or time of a data value is called a(n): A) value stamp. B) time stamp. C) checkpoint. D) check counter

B

A(n) ________ is the relationship between a weak entity type and its owner. A) member chain B) identifying relationship C) jump path D) chain link

B

All of the following are guidelines for better query design EXCEPT: A) understand how indexes are used in query processing. B) use a lot of self-joins. C) write simple queries. D) retrieve on the data that you need.

B

All of the following are new data types added in SQL:200n EXCEPT: A) BIGINT. B) BIT. C) MULTISET. D) XML.

B

All of the following are tasks of data cleaning EXCEPT: A) decoding data to make them understandable for data warehousing applications B) creating foreign keys C)adding time stamps to distinguish values for the same attribute over time D)Generating primary keys for each row of a table

B

An attribute that uniquely identifies an entity and consists of a composite attribute is called a(n): A) composite attribute. B) composite identifier. C) identifying attribute. D) relationship identifier

B

An entity type whose existence depends on another entity type is called a ________ entity. A) strong B) weak C) codependent D) variant

B

Any create command may be reversed by using a ________ command. A) truncate B) drop C) delete D) unpack

B

As a general rule, which of the following data-related IT positions would pay the most? A)data dictionary analyst B)Database Administrator C)Data repository manager D)Data Analyst

B

DDL is typically used during which phases of the development process? A) Implementation B) Physical design C) Analysis D) All of the above

B

Explicit commands to manage transactions are needed when: A) a transaction consists of just one SQL command. B) multiple SQL commands must be run as part of a transaction. C) autocommit is set to off. D) none of the above

B

Extensions defined in SQL-99 that include the capability to create and drop modules of code stored in the database schema across user sessions are called: A) stored procedures. B) Persistent Stored Modules. C) flow control modules. D) none of the above.

B

Given a table named store with 5 fields: store_id, address, city, state, zipcode, why would the following insert command not work? insert into store values ('234 Park Street') A) It would work just fine. B) You must specify the fields to insert if you are only inserting some of the fields. C) There is no table keyword. D) None of the above.

B

In order to embed SQL inside of another language, the ________ statement must be placed before the SQL in the host language. A) GET SQL B) EXEC SQL C) RUN SQL D) SQL SQL

B

One major advantage of the outer join is that: A) information is easily accessible. B) information is not lost. C) the query is easier to write. D) all of the above.

B

The SQL command ________ adds one or more new columns to a table. A) create table B) alter table C) create view D) create relationship

B

The ________ is the structure that contains descriptions of objects such as tables and views created by users. A) SQL B) schema C) catalog D) master view

B

The first in a series of steps to follow when creating a table is to: A) identify columns that must be unique. B) identify each attribute and its characteristics. C) create an index. D) identify columns that must be null

B

The logical representation of an organization's data is called a(n): A) database model. B) entity-relationship model. C) relationship systems design. D) database entity diagram

B

The process of combining data from various sources into a single table or view is called: A)extracting B)joining C)updating D)selecting

B

To eliminate duplicate rows in a query, the ________ qualifier is used in the SQL Select command. A) alter B) distinct C) check D) specific

B

To eliminate duplicate rows in a query, the____qualifier is used in the SQL Select command A)alter B)distinct C)check D)specific

B

What does the following SQL statement do? Update Product_T Set Unit_Price = 775 Where Product_ID = 7 A) Changes the price of a unit called Product_T to 7 B) Changes the unit price of Product 7 to 775 C) Changes the length of the Unit_Price field to 775 D) Updates the Product_T table to have a unit price of 775

B

What result set is returned from the following query? Select Customer_Name, telephone from customers where city in ('Boston','New York','Denver'); A) The Customer_Name and telephone of all customers B) The Customer_Name and telephone of all customers living in either Boston, New York or Denver C) The Customer_Name and telephone of all customers living in Boston and New York and Denver D) The Customer_Name of all customers living in Boston, New York or Denver

B

What result will the following SQL statement produce? Select Avg(standard_price) as average from Product_V; A) The average of all products in Product_V B) The average Standard_Price of all products in Product_V C) The average price of all products D) None of the above

B

What results would the following SQL statement produce? select owner, table_name from dba_tables where table_name = 'CUSTOMER'; A) A listing of all customers in the customer table B) A listing of the owner of the customer table C) A listing of the owner of the customer table as well as customers D) An error message

B

What will be returned when the following SQL statement is executed? Select driver_no, count(*) as num_deliveries from deliveries where state = 'MA' group by driver_no; A) A listing of all drivers who made deliveries to state = 'MA', sorted by driver number B) A listing of each driver who made deliveries to state = 'MA' as well as the number of deliveries that each driver has made to that state C) A count of all of the deliveries made to state = 'MA' by all drivers D) None of the above

B

What will be returned when the following SQL statement is executed? Select driver_no,count(*) as num_deliveries from deliveries group by driver_no; A) A listing of all drivers, sorted by driver number B) A listing of each driver as well as the number of deliveries that he or she has made C) A count of all of the deliveries made by all drivers D) None of the above

B

Which of the following can produce scalar and vector aggregates? A) ORDER BY B) GROUP BY C) HAVING D) SORT

B

Which of the following is a technique for optimizing the internal performance of the relational data model? A) Avoiding indexes on secondary keys B) Clustering data C) Not reporting statistics to save machine resources D) Using random index organizations

B

Which of the following is the wildcard operator in SQL statements? A) < > B) * C) = D) &

B

Which of the following questions is answered by the SQL statement? Select Count (Product_Description) from Product_T; A) How many products are in the table Product_T? B) How many products have product descriptions in the Product Table? C) How many characters are in the field name "Product_Description"? D) How many different columns named "Product_Description" are there in table Product_T?

B

Which of the following will produce the minimum of all standard prices? A) Select standard_price from Product_V where Standard_Price = min; B) Select min(standard_price) from Product_V; C) Select Standard_Price from min(Product_V); D) Select min(Standard_Price) from Product_V where Standard_Price = min(Standard_Price);

B

true

Book, supplier, and state are examples of entity types.

) An entity type name should be all of the following EXCEPT: A) concise. B) specific to the organization. C) as short as possible. D) a singular noun.

C

) In which of the following situations would one have to use an outer join in order to obtain the desired results? A) A report is desired that lists all customers who placed an order. B) A report is desired that lists all customers and the total of their orders. C) A report is desired that lists all customers, the total of their orders during the most recent month, and includes customers who did not place an order during the month (their total will be zero). D) There is never a situation that requires only an outer join.

C

A join in which rows that do not have matching values in common columns are still included in the result table is called a(n): A) natural join. B) equi-join. C) outer join. D) union join.

C

A join operation: A) causes two disparate tables to be combined into a single table or view B)Brings together data from two different fields C) causes two tables with a common domain to be combined into a single table or view D) is used to combine indexing operations

C

A named set of SQL statements that are considered when a data modification occurs are called: A) stored procedures. B) treatments. C) triggers. D) trapdoors.

C

A______is a temporary table used in the FROM clause of an SQL query A) view table B) correlated subquery C) derived table D) none of the above

C

An attribute of an entity that must have a value for each entity instance is a(n): A) optional attribute. B) composite attribute. C) required attribute. D) fuzzy attribute.

C

An attribute that can be broken down into smaller parts is called a(n) ________ attribute. A) associative B) simple C) composite D) complex

C

EXISTS will take a value of ________ if the subquery returns an intermediate results table which contains one or more rows. A) FALSE B) 1 C) TRUE D) undefined

C

Establishing IF-THEN-ELSE logical processing within an SQL statement can be accomplished by: A) using the if-then-else construct. B) using the immediate if statement. C) using the CASE keyword in a statement. D) using a subquery.

C

In an SQL statement, which of the following parts states the conditions for row selection? A) Select B) From C) Where D) Group By

C

Indexes are created in most RDBMSs to: A) provide a quicker way to store data. B) decrease the amount of disk space utilized. C) provide rapid random and sequential access to base-table data. D) increase the cost of implementation

C

RANK and DENSE-RANK are examples of: A) ceilings. B) door functions. C) window functions. D) moving functions.

C

SQL provides the ________ technique, which involves placing an inner query within the WHERE or HAVING clause of an outer query. A) grouping B) joining C) subquery D) union

C

The command for creating a database is: A) create table. B) create view. C) create schema. D) create authorization.

C

The number of entity types that participate in a relationship is called the: A) number. B) identifying characteristic. C) degree. D) counter.

C

What does the following SQL statement do? Alter Table Customer_T Add (Type Varchar (2)); A) Alters the Customer_T table to accept Type 2 Varchars B) Alters the Customer_T table to be a Type 2 Varchar C) Alters the Customer_T table, and adds a field called "Type" D) Alters the Customer_T table by adding a 2-byte field called "Varchar"

C

What result set will the following query return? Select Item_No, description from item where weight > 100 and weight < 200; A) The Item_No and description for all items weighing less than 100 B) The Item_No for all items weighing between 101 and 199 C) The Item_No and description for all items weighing between 101 and 199 D) The Item_No for all items weighing more than 200

C

What will result from the following SQL Select statement? Select min(Product_Description) from Product_V; A) The minimum value of Product_Description will be displayed. B) An error message will be generated. C) The first product description alphabetically in Product_V will be shown. D) None of the above

C

When we consider data in the data warehouse to be time variant, we mean: A)that the time of storage varies B)that there is a time delay between when data are posted and when we report on the data C)data in the warehouse contain a time dimension so that they may be used to study trends and changes D)none of the above

C

Which of the following are most likely to be enforced by a database? A) business organization charts B)Business problems C) Business Rules D) Business Requirements

C

Which of the following finds all groups meeting stated conditions? A) Select B) Where C) Having D) Find

C

Which of the following is true of the order in which SQL statements are evaluated? A) The SELECT clause is always processed first. B) The SELECT clause is always processed last. C) The SELECT clause is processed before the ORDER BY clause. D) The GROUP BY clause is processed before the WHERE clause

C

________ differs from array because it can contain duplicates. A) BIGINT B) XML C) MULTISET D) TABLE

C

________ is a set of commands used to control a database, which includes security. A) DML B) DDL C) DCL D) DPL

C

________ takes a value of true if a subquery returns an intermediate results table which contains one or more rows. A) IN B) HAVING C) EXISTS D) EXTENTS

C

______duplicates data across databases A) a replication server B)data duplication C)data propagation D)redundant replication

C

A join in which the joining condition is based on equality between values in the common columns is called a(n): A) equi-join. B) unilateral join. C) natural join. D) both A and C.

D

A named set of SQL statements that are considered when a data modification occurs are called: A)stored procedures B)treatments C)trapdoors D)triggers

D

A new set of analytical functions added in SQL:2008 is referred to as: A) OLAF functions. B) MOLAP functions. C) average functions. D) OLAP functions.

D

A procedure is: A) stored within the database. B) given a unique name. C) called by name. D) all of the above.

D

A relationship between the instances of a single entity type is called a(n) ________ relationship. A) ternary B) primary C) binary D) unary

D

A relationship where the minimum and maximum cardinality are both one is a(n) ________ relationship. A) optional B) unidirectional C) mandatory link D) mandatory one

D

An operation to join a table to itself is called a: A) sufficient-join. B) inner join. C) outer join. D) self-join.

D

If the DBA wishes to describe all tables in the database, which data dictionary view should be accessed in Oracle? A) dba_tab_privs B) dba_tab_comments C) dba_table_label D) dba_tables

D

TQM stands for: A)Thomas Quinn Mann, a famous data quality innovator B)transforming quality management C)total quality manipulation D)total quality management

D

The ________ clause is used to combine the output from multiple queries into a single result table. A) INTERSECT B) DIVIDE C) COLLATE D) UNION

D

The benefits of a standardized relational language include: A) application longevity. B) reduced training costs. C) cross-system communication. D) all of the above.

D

The common types of entities are: A) strong entities. B) weak entities. C) associative entities. D) all of the above.

D

The most commonly used form of join operation is the: A) outer join. B) union join. C) equi-join. D) natural join.

D

User-defined data types: A) can be a subclass of a standard type. B) can behave as an object. C) can have defined functions and methods. D) can have all of the above.

D

What result set will the following query return? Select Item_No from Order_V where quantity > 10; A) The Item_No of all orders that had more than 10 items B) The Order_Id of all orders that had more than one item C) The Order_Id of all orders that had more than 10 items D) The Item_No of all orders that had 10 or more items

D

Which of the following conditions should exist if an associative entity is to be created? A) All the relationships for the participating entities are many-to-many. B) The new associative entity has independent meaning. C) The new associative entity participates in independent relationships. D) All of the above

D

Which of the following criteria should be considered when selecting an identifier? A) Choose an identifier that is stable. B) Choose an identifier that will not be null. C) Choose an identifier that doesn't have large composite attributes. D) All of the above.

D

Which of the following data-mining applications identifies customers for promotional activity? A)population profiling B)usage analysis C)product affinity D)Target marketing

D

Which of the following is NOT a good characteristic of a data name? A) Relates to business characteristics B) Readable C) Repeatable D) Relates to a technical characteristic of the system

D

Which of the following is a purpose of the SQL standard? A) To specify syntax and semantics of SQL data definition and manipulation B) To specify minimal and complete standards, which permit different degrees of adoption in products C) To define the data structures and basic operations for SQL databases D) All of the above

D

Which of the following is an entity type on which a strong entity depends? A) Owner B) Member C) Attribute D) None of the above

D

Tables

Data is represented in the form of: A) data trees. B) tables. C) data notes. D) chairs.

True

Data structures include data organized in the form of tables with rows and columns. T / F

Mapping derived attributes

Derived attributes are not mapped as a part of the relational schema, They are implemented as a part of the database front-end application

systems analysis

Determining requirements and structuring requirements are associated with

Two relations are created. One represents the entity type in the relationship, and the other is an associative relation to represent the M:N relationship. The primary key of the associative relation consists of two attributes which take their value from the primary key of the other relation.

Discuss how to map a unary many-to-many relationship.

The entity type in the unary relationship is mapped to a relation in the same way as we did for a relation. We next add a foreign key attribute, which maps back to the primary key. This is called a recursive foreign key. So, if we had a relation such as a person supervises one or more persons, the person_id would be a primary key and then there would be a supervisor id which points back to the person_id

Discuss how to map a unary one-to-many relationship.

Each regular entity is transformed into a relation. There are a couple of things that need to be done with some special types of attributes. Composite attributes are broken down into their individual components. Multivalued attributes are broken down into separate relations. For example, if there was a multivalued skill attribute, this would become a skill relation. Also, we ignore derived attributes.

Discuss how you would map a regular entity to a relation.

Each relation (or table) has a unique name. An entry at the intersection of each row and column is atomic and each row is unique. Each attribute (or column) within a table has a unique name. The sequence of rows and columns is insignificant

Discuss the properties of relations

During logical database design, normalization is used as a check and balance to make sure that your E-R diagram is correct as well as your relational schema before doing physical design. Another occasion when you benefit is reverse-engineering an older system, since many of the tables and user views are redundant.

Discuss the two major occasions when you benefit from using normalization

There are two possible cases for associative entities. In one case, you can have an identifier assigned. You would then use this as the primary key. The other case is where the identifier is not assigned. In this case, you would use the primary keys from the other two (or more) relations that are related to the associative entity.

Discuss the two possible scenarios when mapping an associative entity

The three major types of integrity constraints are domain constraints, entity integrity and referential integrity. A domain is a set of attributes assigned to an attribute and consists of the domain name, data type, size and allowable values. The entity integrity rule is designed to ensure that every relation has a primary key and that the data values for the primary key are valid (in particular, not null). The referential integrity constraint is a rule that maintains consistency among the rows of two relations. If there is a foreign key in one relation, there must be a matching primary key in the other relation or the foreign key must be null

Discuss the types of integrity constraints.

A primary key uniquely identifies each row of a relation (or table). It can be either a single column or a composite of two or more columns, which is called a composite key. A foreign key allows us to represent the relationship between two tables. A foreign key in one table is generally a reference to a primary key in another table

Discuss the various relational keys.

A surrogate key should be created when any of the following conditions hold: there is a composite primary key, the natural primary key is inefficient (such as a long name) or the natural primary key is recycled. When you have an associative entity, it is often best to use a surrogate key when you have more than two relations that the associative entity is related to, since the primary key would be a composite of the primary keys of all entities related to the associative entity.

Discuss when it is best to create a surrogate key for an associative entity

A multivalued attribute is one that can take on more than one value. According to the definition of a relation, there can be no multivalued attributes. The reason for this will be seen later when the schema is normalized. A multivalued attribute can be resolved by creating a separate instance for each value and repeating the data from the non-multivalued attributes

Discuss why it is important to remove multivalued attributes from a relation

Discuss the two major occasions when you benefit from using normalization.

During logical database design, normalization is used as a check and balance to make sure that your E-R diagram is correct as well as your relational schema before doing physical design. Another occasion when you benefit is reverse-engineering an older system, since many of the tables and user views are redundant.

Mapping entities with composite attributes into relations

Each component of a composite attribute is mapped as a column of a relation. The composite attribute itself does not appear in the mapped relation

Mapping entities into relations

Each regular entity becomes a relation, Each regular attribute of a regular entity becomes a column of the newly created relation, If an entity has a single unique attribute, then that attribute becomes the primary key in the resulting mapped relation

Discuss how you would map a regular entity to a relation.

Each regular entity is transformed into a relation. There are a couple of things that need to be done with some special types of attributes. Composite attributes are broken down into their individual components. Multivalued attributes are broken down into separate relations. For example, if there was a multivalued skill attribute, this would become a skill relation. Also, we ignore derived attributes.

Discuss the properties of relations.

Each relation (or table) has a unique name. An entry at the intersection of each row and column is atomic and each row is unique. Each attribute (or column) within a table has a unique name. The sequence of rows and columns is insignificant.

Mapping multiple relationships between the same entities

Each relationship is mapped

true

Employee identification number, name, address, and skill are examples of attributes.

When we have a supertype/subtype relationship, we need to assign one entity for the supertype and one for each subtype. The supertype has all attributes common to all subtypes as well as a primary key. Each subtype relation has the primary key of the supertype as well as any attributes that are specific to that subtype. Finally, we assign one or more attributes to the supertype to function as subtype discriminators

Explain how subtype/supertype relationships are converted to relations

A candidate key is an attribute or a combination of attributes that uniquely identifies a row in a relation. A candidate key must be nonredundant and must also uniquely identify each row. When we look at functional dependencies and candidate keys, we can always say that a determinant is always a candidate key.

Explain what a candidate key is and how it might be used

A function has only input parameters but can return multiple values.

False

A referential integrity constraint specifies that the existence of an attribute in one table depends upon the existence of a foreign key in the same or another table.

False

A routine is a named set of SQL statements that are considered when a data modification occurs.

False

A single value returned from an SQL query that includes an aggregate function is called a vector aggregate.

False

A subquery in which processing the inner query depends on data from the outer query is called a codependent query.

False

An equi-join is a join in which one of the duplicate columns is eliminated in the result table.

False

Combining a table with itself results in a faster query.

False

Count(*) tallies only those rows that contain a value, while Count counts all rows.

False

DBA_USERS contains comments on all tables in an Oracle database.

False

DBA_USERS contains comments on all tables in an oracle database(T/F)

False

EXISTS takes a value of false if the sub query returns an intermediate result set

False

EXISTS takes a value of false if the subquery returns an intermediate result set.

False

IF-THEN-ELSE logical processing cannot be accomplished within an SQL statement.

False

SQL has been implemented only in the mainframe and midrange environments.

False

The DELETE TABLE DDL command is used to remove a table from the database.

False

The following query will execute without errors. select customer.customer_name, salesman.sales_quota from customer where customer.salesman_id = (select salesman_id where lname = 'SMITH');

False

The following two SQL statements will produce different results. Select last_name, first_name from customer where state = 'MA' or state = 'NY' or state = 'NJ' or state = 'NH' or state = 'CT'; Select last_name, first_name from customer where state in ('MA','NY','NJ','NH','CT');

False

The natural join is very rarely used.

False

Transaction integrity commands are not used to identify whole units of database changes that must be completed in full for the database to retain integrity.

False

Triggers can be used to ensure referential integrity, enforce business rules, create audit trails, replicate tables, but cannot call other triggers.

False

When a subquery is used in the FROM clause, it is called a denied table.

False

bottom up approach

Gathering the information you need for data modeling by reviewing specific business documents handled within the system describes the

A weak entity becomes a relation. However, since a weak entity instance does not exist by itself, we must create a relation with the primary key from the strong relation as the primary key, as well as the identifying attribute.

How do you convert weak entities to relations?

minimum cardinality is one

If entity B is a mandatory participant, then:

Referential integrity constraint lines

In a relational schema lines pointing from the foreign key to the corresponding primary key are referred to as referential integrity constraint lines

referential integrity constraint lines

In a relational schema lines pointing from the foreign key to the corresponding primary key are referred to as this.

Mapping M:N unary relationships

In addition to the relation representing the entity involved in a unary M:N relationship, another relation is created to represent the M:N relationship itself, This new relation has two foreign keys, both of them corresponding to the primary key of the relation representing the entity involved in the unary M:N relationship, Each of the foreign keys is used as a part of the composite primary key of the new relation

Mapping M:N relationships

In addition to the two relations representing the two entities involved in the M:N relationship, another relation is created to represent the M:N relationship itself, This new relation has two foreign keys, corresponding to the primary keys of the two relations representing the two entities involved in the M:N relationship, The two foreign keys form the composite primary key of the new relation

Referential integrity constraint

In each row of a relation containing a foreign key, the value of the foreign key EITHER matches one of the values in the primary key column of the referred relation OR the value of the foreign key is null (empty).

create table

In the SQL language, the ________ statement is used to make table definitions. A) create session B) create table C) create index D) select

Candidate

In the figure below, Customer_ID in the CUSTOMER Table is which type of key? A) Composite B) Candidate C) Standard D) Grouped

TRUE.

In the figure below, each employee has exactly one manager. Answer : T / F

COMPOSITE

In the figure below, the primary key for "Order Line" is which type of key? A) Composite B) Foreign C) Standard D) Grouped

An associative entity

In the figure below, what is depicted? A) A one-to-one relationship B) A unary relationship C) A one-to-many relationship D) An associative entity

Recursive foreign

In the figure below, what type of key is depicted? A) Primary B) Recursive primary C) Composite D) Recursive foreign

Union join

Includes all data from each table that was joined

relational DBMS (RDBMS)

Most contemporary commercial DBMS software packages, are relational DBMS (RDBMS) software packages

Mapping entities with candidate keys (multiple unique attributes) into relations

One of the candidate keys is chosen by database designer the as a primary key during the mapping process, Other candidate keys are mapped as non-primary key columns

A component is always used in only one item.

Referring to the figure below, which of the following is NOT true? A) A component is part of an item. B) A component is always used in only one item. C) A component can be part of an item. D) A component may be used in many items

What does the following SQL statement do? Select * From Customwr Where Cust_Type = "Best"

Selects all the fields from the customer table for each row with a customer labeled "Best"

True

T/F A business rule is a statement that defines or constrains some aspect of the business

False

T/F A ternary relationship is equivalent to three binary relationships

True

T/F A time stamp is a time value that is associated with a data value

True

T/F An attribute whose values can be calculated from related attribute values is called a derived attribute.

True

T/F An entity is a person, place, object, event, or concept in the user environment about which the organization wishes to maintain data

True

T/F Data modeling is about documenting rules and policies of an organization that govern data.

False

T/F Most systems developers believe that dat modeling is the least important part of the systems development process.

True

T/F One reason to use an associative entity is if the associative entity has one or more attributes in addition to the identifier

True

T/F Participation is a relationship may be optional or mandatory

True

T/F Relationships represent action being taken using a verb phrase

False

T/F The degree of a relationship is the number of attributes that are associated with it

False

T/F The intent of a business rule is to break down business structure

True

T/F The relationship between a weak entity type and its owner is an identifying relationship.

True

T/F When choosing an identifier, choose one that will not change its value often

True

T/F Τhe E-R model is used to construct a conceptual model

Mapping ternary relationships

Ternary relationships are used as many-to-many-to-many relationshipsA new relation is created with foreign keys from the participating entities forming a composite primary key of the new relation

What result is returned from the following query? Select Customer_Name, telephone From customers Where city in ('Boston', 'New York', 'Denver');

The Customer_Name and telephone of all customers living in either Boston, New York, or Denver

What result will the following SQL statement produce? Select Avg(standard_price) as average from Product_V;

The average Standard_Price of all products in Product_V

top down approach

The data modeling perspective that derives the business rules for a data model from an intimate understanding of the nature of the business

Identifying Owner

The entity type on which the weak entity type depends.

Ternary

The figure below is an example of mapping which type of relationship? A) First B) Second C) Unary D) Ternary

Maximum Cardinality

The maximum number of instances of one entity that may be associated with each instance of another entity.

Minimum Cardinality

The minimum number of instances of one entity that may be associated with each instance of another entity

merge

The need to ________ relations commonly occurs when different views need to be integrated. A) metadata B) system C) drop D) merge

fourth normal form.

The normal form which deals with multivalued dependencies is called: A) fifth normal form. B) fourth normal form. C) Boyce-Codd normal form. D) sixth normal form.

Boyce-Codd normal form.

The normal form which removes any remaining functional dependencies because there was more than one primary key for the same nonkeys is called: A) fifth normal form. B) fourth normal form. C) Boyce-Codd normal form. D) sixth normal form.

Degree

The number of entity types that participate in a relationship

true

The primary deliverable for the conceptual data-modeling step within the analysis phase is an entity-relationship diagram.

true

The purpose of the conceptual data model is to show as many rules about the meaning and interrelationships among data as possible.

Mapping 1:M unary relationships

The relation mapped from an entity involved in a 1:M unary relationship contains a foreign key that corresponds to its own primary key

Mapping 1:M relationships

The relation mapped from the entity on the M side of the 1:M relationship has a foreign key that corresponds to the primary key of the relation mapped from the 1 side of the 1:M relationship

Discuss the types of integrity constraints.

The three major types of integrity constraints are domain constraints, entity integrity and referential integrity. A domain is a set of attributes assigned to an attribute and consists of the domain name, data type, size and allowable values. The entity integrity rule is designed to ensure that every relation has a primary key and that the data values for the primary key are valid (in particular, not null). The referential integrity constraint is a rule that maintains consistency among the rows of two relations. If there is a foreign key in one relation, there must be a matching primary key in the other relation or the foreign key must be null.

Discuss the two possible scenarios when mapping an associative entity.

There are two possible cases for associative entities. In one case, you can have an identifier assigned. You would then use this as the primary key. The other case is where the identifier is not assigned. In this case, you would use the primary keys from the other two (or more) relations that are related to the associative entity.

A transaction is the complete set of closely related update commands that must all be done, or none of them done, for the database to remain valid.

True

Adding the DISTINCT keyword to a query eliminates duplicates.

True

An SQL query that implements an outer join will return rows that do not have matching values in common columns

True

An insert command does not need to have the fields listed.

True

Figuring out what attributes you want in your query before you write the query will help with query writing.

True

If multiple Boolean operators are used in an SQL statement, NOT is evaluated first, then AND, then OR.

True

In order to find out what customers have not placed an order for a particular item, one might use the NOT qualifier along with the IN qualifier.

True

The FROM clause is the first statement processed in an SQL command.

True

The UNION clause is used to combine the output from multiple queries into a single result table.

True

The WHERE clause includes the conditions for row selection within a single table or view and the conditions between tables or views for joining.

True

The advantages of SQL-invoked routines are flexibility, efficiency, shareability and applicability.

True

The asterisk (*) wildcard designator can be used to select all fields from a table as well as in WHERE clauses when an exact match is not possible.

True

The following SQL statement is an example of a correlated subquery. select first_name, last_name, total_sales from salesman s1 where total_sales > all (select total_sales from salesman s2 where s1.salesman_id != s2.salesman_id);

True

Discuss how to map a unary many-to-many relationship.

Two relations are created. One represents the entity type in the relationship, and the other is an associative relation to represent the M:N relationship. The primary key of the associative relation consists of two attributes which take their value from the primary key of the other relation.

one must be able to check the output of a CASE tool.

Understanding the steps involved in transforming EER diagrams into relations is important because: A) one must be able to check the output of a CASE tool. B) there are rarely legitimate alternatives from which to choose. C) CASE tools can model any situation. D) CASE tools model hypothetical business problems

Business rules

User defined constraints that specify restrictions on databases that are not a part of the standard notation for creating ER diagrams

Discuss why it is a good idea to create an instance of your relational schema with sample data.

Using sample data allows you to test any assumptions that you may have regarding the design. In addition, it provides a convenient way to check the accuracy of your design and helps to improve communication with users. A final benefit is that you will be able to develop prototype applications and sample queries with the data.

Mapping weak entities

Weak entities are mapped in a same way as regular entities with one addition: The resulting relation has a composite primary key that is composed of the partial identifier and the foreign key corresponding to the primary key of the owner entity

a conceptual data model is created

What happens during the Analysis phase in Requirements Structuring?

ER diagramming

What is the most common type of conceptual data modeling?

create two new relations, one containing the multivalued attribute.

When a regular entity type contains a multivalued attribute, one must: A) create a single relation with multiple lines for each instance of the multivalued attribute. B) create two new relations, one containing the multivalued attribute. C) create two new relations, both containing the multivalued attribute. D) delete the relation and start over.

No two rows in a relation are identical.

Which of the following are properties of relations? A) Each attribute has the same name. B) No two rows in a relation are identical. C) There are multivalued attributes in a relation. D) All columns are numeric

Given a table named store with 5 fields: store_id, address, city, state, zip code, why would the following insert command not work? Insert into store values ('234 Park Street')

You must specifiy the fields to insert if you are only inserting some of the fields(they didnt even enter zip code, state, or city)

attribute

a named property or characteristic of an entity that is of interest to the organization

design strategy

a particular approach to developing an information system. It includes statements on the functionality, hardwre and system software platform, and method for acquisition.

binary relationship

a relationship between instances of two entity types

unary relationship

a relationship between the instances of one entity type

repeating group

a set of two or more multivalued attributes that are logically related

ternary relationship

a simultaneous relationship among instances of three entity types

Domain Constraint

all values in each column must be from the same predefined domain

multivalued attribute

an attribute that may take on more than one value for each entity instance

________ is a component of the relational data model included to specify business rules to maintain the integrity of data when they are manipulated. A) Business rule constraint B) Data integrity C) Business integrity D) Data structure

data integrity

A nonkey attribute is also called a(n): A) column. B) unimportant datum. C) descriptor. D) address.

descriptor

The attribute on the left-hand side of the arrow in a functional dependency is the: A) candidate key. B) determinant. C) foreign key. D) primary key.

determinant

A primary key whose value is unique across all relations is called a(n): A) global primary key. B) inter-table primary key. C) enterprise key. D) foreign global key.

enterprise key

The ________ states that no primary key attribute may be null. A) referential integrity constraint B) entity integrity rule C) partial specialization rule D) range domain rule

entity integrity rule

A synonym is an attribute that may have more than one meaning.

false

A transversal dependency is a functional dependency between two or more nonkey attributes.

false

An anomaly is a type of flaw in the database server.

false

An enterprise key is a foreign key whose value is unique across all relations.

false

An identifier assigned to an associative entity is also called a cross-relation key.

false

Anomalies do not generally arise out of transitive dependencies.

false

CASE tools can model more complex data relationships, such as ternary relationships.

false

Data integrity consists of powerful operations to manipulate data stored in relations.

false

In the relational data model, associations between tables are defined through the use of primary keys.

false

The entity integrity rule states that a primary key attribute can be null.

false

The primary key of the many side migrates to the one side when transforming a one-to-many relationship.

false

The relational data model does, at this time, directly support subtype/supertype relationships.

false

The truncate table statement in SQL creates a new table.

false

There can be multivalued attributes in a relation.

false

When all multivalued attributes have been removed from a relation, it is said to be in: A) first normal form. B) second normal form. C) Boyce-Codd normal form. D) third normal form.

first normal form

An attribute in a relation of a database that serves as the primary key of another relation in the same database is called a: A) link attribute. B) link key. C) foreign key. D) foreign attribute.

foreign key

The normal form which deals with multivalued dependencies is called: A) fifth normal form. B) fourth normal form. C) Boyce-Codd normal form. D) sixth normal form.

fourth normal form

A constraint between two attributes is called a(n): A) functional relation. B) attribute dependency. C) functional dependency. D) functional relation constraint.

functional dependency

lets

go

An attribute that may have more than one meaning is called a(n): A) homonym. B) alias. C) double defined attribute. D) synonym.

homonym

A form of database specification which maps conceptual requirements is called: A) logical specifications. B) response specifications. C) security specifications. D) physical specifications.

logical specifications

Mapping 1:1 relationships

mapped the same as 1:M relationships primary key of another resulting relation, One of the mapped relations is chosen to have a foreign key referring to the primary key of the other mapped relation, In cases when there is no particular advantage in choosing which resulting relation will include a foreign key, the choice can be arbitrary, In other cases one choice can be more efficient than the other

The need to ________ relations commonly occurs when different views need to be integrated. A) metadata B) system C) drop D) merge

merge

________ are anomalies that can be caused by editing data in tables. A) Insertion B) Deletion C) Modification D) Creation

modification

Understanding the steps involved in transforming EER diagrams into relations is important because: A) one must be able to check the output of a CASE tool. B) there are rarely legitimate alternatives from which to choose. C) CASE tools can model any situation. D) CASE tools model hypothetical business problems.

one must be able to check the output of a CASE tool

Designer-created primary key

primary key column, not called for by the original requirements, added to a table by the database designer Often used in conjunction with the autonumber data type option

A two-dimensional table of data sometimes is called a: A) group. B) set. C) declaration. D) relation.

relation

Which of the following violates the atomic property of relations? A) Sam B) Hinz C) Sam Hinz D) Atomic

sam hinz

Which of the following is NOT a reason to create an instance of a relational schema with sample data? A) Sample data can be used to improve user communications. B) Sample data can be used for prototype generation. C) Sample data can reverse database implementation errors. D) Sample data provide a convenient way to check the accuracy of your design.

sample data can reverse database implementation errors

attributes

ssn, last name, and first name are examples of what?

Relation

table in a relational database: In order for a table to be a relation the following conditions must hold: Each column must have a name (within one table, each column name must be unique), Within one table, each row must be unique, Within each row, each value in each column must be single valued (multiple values of the content represented by the column are not allowed in any rows of the table), All values in each column must be from the same (predefined) domain, Order of columns is irrelevant, Order of rows is irrelevant

Data is represented in the form of: A) data trees. B) tables. C) data notes. D) chairs.

tables

A candidate key must satisfy all of the following conditions EXCEPT: A) the key must uniquely identify the row. B) the key must indicate the row's position in the table. C) the key must be nonredundant. D) each nonkey attribute is functionally dependent upon it.

the key must indicate the row's position in the table

degree of relationship

the number of entity types that participate in a relationship

cardinality

the number of instances of entity B that can (or must)be associated with each instance of entity A

A functional dependency between two or more nonkey attributes is called a: A) partial functional dependency. B) partial nonkey dependency. C) transitive dependency. D) partial transitive dependency.

transitive dependency

A partial functional dependency is a functional dependency in which one or more nonkey attributes are functionally dependent on part (but not all) of the primary key.

true

A referential integrity constraint is a rule that maintains consistency among the rows of two relations.

true

A relation in fifth normal form may not contain any anomalies.

true

A well-structured relation contains minimal redundancy and allows users to manipulate the relation without errors or inconsistencies.

true

All values that appear in a column of a relation must be taken from the same domain.

true

Data structures include data organized in the form of tables with rows and columns.

true

If an identifier is not assigned, the default primary key for an associative relation consists of the two primary key attributes from the other two relations.

true

One property of a relation is that each attribute within a relation has a unique name.

true

The allowable range of values for a given attribute is part of the domain constraint.

true

The columns of a relation can be interchanged without changing the meaning or use of the relation.

true

View integration is the process of merging relations together.

true

Relational schema

visual depiction of the relational database model

A relation that contains minimal redundancy and allows easy use is considered to be: A) clean. B) simple. C) complex. D) well-structured.

well-structured

diamond

what shape is a relationship

oval

what shape is an attribute

rectangle

what shape is an entity

underline

what shape is an identifier


Conjuntos de estudio relacionados

ICT-1 Multimedia Lesson 2 (Part 1)

View Set

NCLEX Review: Structural, Infectious, & Inflammatory Cardiac Disorders

View Set

Medical Terminology: Exam 1 - LC Ready

View Set

MGMT 2103 - Module 12 (Chapter 16)

View Set

Science 902 self test 1 study guide

View Set