Brandon Gagon
Quiz por , criado more than 1 year ago

SQL/ Transactions / Data Integrity

51
0
0
Sem etiquetas
Brandon Gagon
Criado por Brandon Gagon quase 8 anos atrás
Fechar

SQL/ Transactions / Data Integrity

Questão 1 de 40

1

Which of the following is a benefit of using a DBMS?

Selecione uma das seguintes:

  • They provide full security to data using private/public key encryption

  • They create automatic backups

  • They help create an environment for end users to have access to more data

  • They provide seamless Internet access to database data

Explicação

Questão 2 de 40

1

The hierarchical database model is based on a ____.

Selecione uma das seguintes:

  • tree structure

  • lack of a parent segment

  • lack of a child segment

  • matrix

Explicação

Questão 3 de 40

1

Because an RDBMS hides the system's complexity from the user/designer, ____.

Selecione uma das seguintes:

  • it does not exhibit data independence

  • it does not exhibit structural independence

  • data management is easier

  • data management is very difficult

Explicação

Questão 4 de 40

1

The ERD is used to graphically represent the ____ database model.

Selecione uma das seguintes:

  • condensed

  • physical

  • logical

  • conceptual

Explicação

Questão 5 de 40

1

The property of ____ enables an entity subtype to inherit the attributes and relationships of the supertype.

Selecione uma das seguintes:

  • subtype discriminator

  • inheritance

  • specialization hierarchy

  • entity supertype

Explicação

Questão 6 de 40

1

At the implementation level, the supertype and its subtype(s) depicted in the specialization hierarchy maintain a ____ relationship.

Selecione uma das seguintes:

  • none

  • 1:1

  • 1:M

  • M:N

Explicação

Questão 7 de 40

1

Which command would be used to delete the table row where the P_Code = '2238/QPD'?

Selecione uma das seguintes:

  • DELETE FROM PRODUCT
    WHERE P_CODE = '2238/QPD';

  • REMOVE FROM PRODUCT
    WHERE P_CODE = '2238/QPD';

  • ERASE FROM PRODUCT
    WHERE P_CODE = '2238/QPD';

  • ROLLBACK FROM PRODUCT
    WHERE P_CODE = '2238/QPD';

Explicação

Questão 8 de 40

1

Which command is used to select partial table contents?

Selecione uma das seguintes:

  • SELECT <column(s)>
    FROM <Table name>
    WHERE <Item>;

  • LIST <column(s)>
    FROM <Table name>
    WHERE <Conditions>;

  • SELECT <column(s)>
    FROM <Table name>
    WHERE <Conditions>;

  • LIST<column(s)>
    FROM <Table name>
    WHERE <Item>;

Explicação

Questão 9 de 40

1

Which query will output the table contents when the value of V_CODE is equal to 21344?

Selecione uma das seguintes:

  • SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE
    FROM PRODUCT
    WHERE V_CODE <> 21344;

  • SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE
    FROM PRODUCT
    WHERE V_CODE <= 21344;

  • SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE
    FROM PRODUCT
    WHERE V_CODE = 21344;

  • SELECT P_DESCRIPT, P_INDATE, P_PRICE, V_CODE
    FROM PRODUCT
    WHERE V_CODE => 21344;

Explicação

Questão 10 de 40

1

What is the command used to list the P_CODE, P_DESCRIPT, P_INDATE, and P_PRICE fields from the Product table in ascending order by P_PRICE?

Selecione uma das seguintes:

  • SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE
    FROM PRODUCT
    SEQUENCE BY P_PRICE;

  • SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE
    FROM PRODUCT
    LIST BY P_PRICE;

  • SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE
    FROM PRODUCT
    ORDER BY P_PRICE;

  • SELECT P_CODE, P_DESCRIPT, P_INDATE, P_PRICE
    FROM PRODUCT
    ASCENDING BY P_PRICE;

Explicação

Questão 11 de 40

1

The basic SQL aggregate function that gives the total of all values for a selected attribute in a given column is ____.

Selecione uma das seguintes:

  • COUNT

  • MIN

  • MAX

  • SUM

Explicação

Questão 12 de 40

1

____ is used to tally the number of specific "values" of an attribute.

Selecione uma das seguintes:

  • SUM

  • TOTAL

  • COUNT

  • ADD

Explicação

Questão 13 de 40

1

UPDATE tablename
*****
[WHERE conditionlist];
What command replaces the ***** in the above statement?

Selecione uma das seguintes:

  • SET columnname = expression

  • columnname = expression

  • expression = columnname

  • LET columnname = expression

Explicação

Questão 14 de 40

1

When using a(n) ____ join, only rows that meet the given criteria are returned.

Selecione uma das seguintes:

  • full

  • inner

  • outer

  • set

Explicação

Questão 15 de 40

1

What is the syntax for a left outer join?

Selecione uma das seguintes:

  • SELECT column-list
    FROM table1 OUTER JOIN table2 LEFT
    WHERE join-condition

  • SELECT column-list
    FROM table1 LEFT [OUTER] JOIN table2
    ON join-condition

  • SELECT column-list
    WHERE LEFT table1 = table 2

  • SELECT column-list
    FROM table1 LEFT table2 [JOIN]
    WHERE join-condition

Explicação

Questão 16 de 40

1

In subquery terminology, the first query in the SQL statement is known as the ____ query.

Selecione uma das seguintes:

  • outer

  • left

  • inner

  • base

Explicação

Questão 17 de 40

1

In a subquery, which query is executed first?

Selecione uma das seguintes:

  • leftmost

  • rightmost

  • innermost

  • outermost

Explicação

Questão 18 de 40

1

Creating the conceptual design, selecting DBMS software, creating the logical design, and creating the physical design are part of the ____ phase.

Selecione uma das seguintes:

  • database initial study

  • database design

  • implementation and loading

  • testing and evaluation

Explicação

Questão 19 de 40

1

Which of the conceptual design steps defines entities, attributes, and relationships?

Selecione uma das seguintes:

  • Database analysis and requirements

  • Entity relationship modeling and normalization

  • Data model verification

  • Distributed database design

Explicação

Questão 20 de 40

1

What is the primary objective of database design?

Selecione uma das seguintes:

  • To create the most efficient database possible

  • To create complete, normalized, nonredundant, and fully integrated conceptual, logical, and physical database models

  • To create the fastest queries

  • To be able to add data quickly

Explicação

Questão 21 de 40

1

The most common algorithms for concurrency control are locks, ____ stamping, and optimistic methods.

Selecione uma das seguintes:

  • date

  • time

  • hour

  • minute

Explicação

Questão 22 de 40

1

____ requires that all operations of a transaction be completed.

Selecione uma das seguintes:

  • Specificity

  • Atomicity

  • Durability

  • Time Stamping

Explicação

Questão 23 de 40

1

The ____ establishes the order in which the operations within concurrent transactions are executed.

Selecione uma das seguintes:

  • transaction log

  • timer

  • lock manager

  • scheduler

Explicação

Questão 24 de 40

1

When is the implicit beginning of a transaction?

Selecione uma das seguintes:

  • When the database is started

  • When a table is accessed for the first time

  • When the first SQL statement is encountered

  • When the COMMIT command is issued

Explicação

Questão 25 de 40

1

A(n) ____ phase in a two-phase lock is when a transaction releases all locks and cannot obtain any new lock.

Selecione uma das seguintes:

  • growing

  • shrinking

  • locking

  • unlocking

Explicação

Questão 26 de 40

1

What is a consistent database?

Selecione uma das seguintes:

  • One in which all tables have foreign keys

  • One in which all data integrity constraints are satisfied

  • One in which all tables are normalized

  • One in which all SQL statements only update one table at a time

Explicação

Questão 27 de 40

1

A transaction acquires a ____ prior to data access.

Selecione uma das seguintes:

  • grain

  • timestamp

  • lock

  • key

Explicação

Questão 28 de 40

1

Changes are permanently applied to the database during the ____ phase of a transaction.

Selecione uma das seguintes:

  • commit

  • write

  • input

  • output

Explicação

Questão 29 de 40

1

The phenomenon of ____ occurs when two transactions, T1 and T2, are executed concurrently and the first transaction (T1) is rolled back after the second transaction (T2) has already accessed the uncommitted data—thus violating the isolation property of transactions.

Selecione uma das seguintes:

  • lost updates

  • uncommitted data

  • transaction failure

  • inconsistent retrieval

Explicação

Questão 30 de 40

1

____ occur when a transaction calculates some summary (aggregate) functions over a set of data while other transactions are updating the data.

Selecione uma das seguintes:

  • lost updates

  • uncommitted data

  • transaction failures

  • inconsistent retrievals

Explicação

Questão 31 de 40

1

The scheduler facilitates data ____ to ensure that two transactions do not update the same data element at the same time.

Selecione uma das seguintes:

  • durability

  • isolation

  • atomicity

  • serializability

Explicação

Questão 32 de 40

1

Which is not a DML statement?

Selecione uma das seguintes:

  • CREATE TABLE

  • SELECT

  • INSERT

  • DELETE

Explicação

Questão 33 de 40

1

What feature is a DDBMS disadvantage?

Selecione uma das seguintes:

  • Data is located near the "greatest demand" site

  • Growth facilitation

  • Reduced operating cost

  • lack of standards

Explicação

Questão 34 de 40

1

What feature is a DDBMS advantage?

Selecione uma das seguintes:

  • Greater difficulty in managing the data environment

  • Less danger of a single-point failure

  • Increased training cost

  • Complexity of management and control

Explicação

Questão 35 de 40

1

____ distributed database systems integrate different types of centralized DBMSs over a network.

Selecione uma das seguintes:

  • Homogeneous

  • Heterogeneous

  • Fully homogeneous

  • Fully heterogeneous

Explicação

Questão 36 de 40

1

____ transparency allows a transaction to update data at several network sites.

Selecione uma das seguintes:

  • Transaction

  • Distribution

  • Failure

  • Performance

Explicação

Questão 37 de 40

1

____ transparency ensures that the system will continue to operate in the event of a node failure.

Selecione uma das seguintes:

  • Transaction

  • Distribution

  • Failure

  • Performance

Explicação

Questão 38 de 40

1

The ____ contains the description of the entire database as seen by the database administrator.

Selecione uma das seguintes:

  • distributed global dictionary

  • distributed data dictionary

  • distributed global schema

  • distributed data schema

Explicação

Questão 39 de 40

1

____ query optimization means that the DDBMS finds the most cost-effective access path without user intervention.

Selecione uma das seguintes:

  • Static

  • Dynamic

  • Automatic

  • Commit

Explicação

Questão 40 de 40

1

____ query optimization takes place at execution time.

Selecione uma das seguintes:

  • Automatic

  • Static

  • Manual

  • Dynamic

Explicação