COP4751 Midterm Exam Study Guide

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

From the point of view of query optimization which query is faster? (I) SELECT FirstName, LastName, Address, City, State, ZipFROM Customers; (II) SELECT *FROM Customers;

(I)

From the point of view of query optimization which query is faster? (I) SELECT Customers.CustomerID, Customers.Name, Sales.LastSaleDateFROM CustomersINNER JOIN SalesON Customers.CustomerID = Sales.CustomerID; (II) SELECT Customers.CustomerID, Customers.Name, Sales.LastSaleDateFROM Customers, SalesWHERE Customers.CustomerID = Sales.CustomerID;

(I)

From the point of view of query optimization which query is faster? (I) SELECT nameFROM employeeWHERE salary = (SELECT MAX(salary) FROM employee_details)AND age = (SELECT MAX(age) FROM employee_details)AND emp_dept = 'Electronics'; (II) SELECT nameFROM employeeWHERE (salary, age ) = (SELECT MAX (salary), MAX (age)FROM employee_details)AND dept = 'Electronics';

(II)

Which of the following concurrency control protocols ensure both conflict serialzability and freedom from deadlock? (I) 2-phase locking (II) Time-stamp ordering

(II)

Which of (a) to (d) is false about PHP?

(d) PHP can NOT be use to add, delete, modify data from databases

What should be the correct syntax to write a PHP code?

<?php echo "Hi"; ?>

Any non-serial interleaving of transactions T1 and T2 for concurrent execution leads to:

A schedule that is not conflict serializable

A transaction may not always complete its execution successfully. Such a transaction is termed

Aborted

With regards to transaction processing, any Database Management System should be capable of:

All of the Above

What is ACID properties of Transactions?

Atomicity, Consistency, Isolation, Durability

A transaction completes its execution is said to be

Committed

Which is refers to a stalemate situation due to which no further progress is possible as transactions await response of each other:

Deadlock

Which of the following locks the item from access of any type?

Exclusive Lock

Which of the following statements is false about query optimization?

None of the above.

Which of the following PHP statement/statements will store 111 in variable num? (i) int $num = 111; (ii) int mum = 111; (iii) $num = 111; (iv) 111 = $num;

Only (iii)

Consider the following action: TRANSACTION ..... Commit; Rollback; What does Rollback do?

Options: Undoes the transactions before commit Clears all transactions Redoes the transactions before commit No action Undoes the transaction before commit IS WRONG

Which of the following is false?

PHP cannot be embedded into html.

In order to undo the work of transaction after last commit which one should be used?

Rollback

Which of the following locks the item from change/write but not from read?

Shared Lock

Consider the following schedule for transactions T1, T2 and T3: T1T2T3 R(X)R(Y)R(Y) W(Y)W(X)W(X) R(X) W(X) Which one of the schedules below is the correct serialization of the above?

T1->>T3->>T2

Which of the following statements is true about query optimization?

The query execution plan is developed by the relational database system.

Consider the following two transactions: T1: R(A), W(A), R(B), W(B). T2: R(B), R(C), W(C), W(B). Consider the following interleaved schedule of the two transactions:RT1(A), RT2(B), RT2(C), WT1(A), RT1(B), WT1(B), WT2(C), WT2(B). Which of the following statements is true?

This schedule is not conflict serializable.

A __________ consists of a sequence of query and/or update statements.

Transaction

Consider the following expression query trees: Do these two expression query trees generate the same set of tuples?

Yes

What does PHP stand for? (i) Hypertext Preprocessor (ii) Preprocessor Home Page (iii) Personal Home Page

only(i)


Conjuntos de estudio relacionados

Ch. 7 Rome's Three Heirs, 500-950

View Set

Introduction to MLA Documentation

View Set

Product life cycle and strategies

View Set