Referential integrity Constraints control relationships B
between _.
[A]operations of an object
[B]tables in a database
[C]attributes in a table
[D]database instances
Choose the right statement below to declare zero or A
one occurrence of an Element in DTD.
[A]<"ELEMENT element-name (childname?)>
[B]<IELEMENT element-name (child-name+)>
[C]<'ELEMENT element-name (child-name*)>
[D]<IELEMENT element-name (child-name)>
Given the relation Employee(SSN. FNAME. LNAME. A
SALARY). Select the right query below
to find the employee(s) who has the lowest salary in the
company
[A]SELECT LNAME. FNAME. SALARY FROM Employee
WHERE SALARY IN (SELECT
MIN(SALARY) FROM Employee)
[B]SELECT LNAME. FNAME. SALARY FROM Employee
WHERE SALARY >= ALL
(SELECT SALARY FROM Employee)
[C]SELECT LNAME. FNAME. SALARY FROM Employee
WHERE SALARY < MAX
(SELECT SALARY FROM Employee)
[D]None of the others
Given a relation R(A.B.C.D). Which of the followings is B
trivial?
[A]A->BCD
[B]A->->BCD
[C]A->AB
[D]A->->AB
Which of the following is NOT a standard aggregation C
operator?
[A]SUM
[B]AVG
[C]GROUP
[D]COUNT
, DBI202 Final Exam Questions & Answers
Select the well-formed XML B
[A]All of the others
[B]<? xml version = "1.0" ?>
<MovieData>
<Movie tiHe="StarWar*><Year>1997</Yearx/MovJe>
</MovieData>
[C]<? xml version - "1 0' ?>
<MovieData>
<Movie Me-'StarWaf*><Year>1997</Year></Movie>
</Movies>
[D]<? xml version = 1 0 7>
<MovieData>
<Movie trtle-"StarWar"><Year>1997</Movie></Year>
</MovieData>
Which of the followings is true? A
[A]The Entity Relationship (ER) model represents the
structure of data graphically
[B]The ER model is a low level database design
IC]The ER model represents the operation on data
[D]All of the others
In the three-tier architecture, the database tier's D
function is to
[A]All of the others.
[B]Execute the business logic of the organization
operating the database.
[C]Manage the interactions with the user.
[D]Execute queries that are requested from the
application tier.
Choose a right answer C
[A]When a privilege is granted, it cannot be revoked
[B]Privileges cannot be granted on a view
[C]An authorization ID may be granted privileges from
others or may grve its
privileges to others
[D]All of the others
Which of the followings is part of data model? C
[A]Operations on the data
[B]Constraints on the data
[C] All of the others |
[D]Structure of the data
, DBI202 Final Exam Questions & Answers
Exception handler in PSM is defined as follows: C
DECLARE <where to go next> HANDLER FOR condition
list> <statement>
The <where to go next> clause can be:
[A]UNDO
[B]EXIT
[C]All of the others
[D]CONTINUE
In SQL language, the command/statement that let you A
add an attribute to a relation
is_
[A]Alter
[B]None of the others
[C]Insert
[D]Update
Choose the right statement A
[A]All of the others.
[B]The syntax to remove a trigger is. DROP
TRIGGER<trigger_name>
[C]Use ALTER TRIGGER to change the definition of a
trigger
[D]You can remove a trigger by dropping it or by
dropping the trigger table.
Consider the Dalalog rule H(xy) <- Sfx. y) AND x > 2 D
AND y < 6. Relation S(x y) has 3 tuples
(2.3). (3.5). and (4.6). What is about H?
[A]H has a tuple (2.3)
[B]H has 3 tuples (2.3) and (3.5) and (4.6)
[C]H has 2 tuples (2.3) and (3.5)
[D]*H has a tuple (3.5)
Select the valid query to declare the foreign key D
presC# of the relation Studiolname. address.
presC#) that references the cert of the relation
MovieExeclname. address. cert#. netWorth):
[A]All of the others.
[B]CREATE TABLE Studio (name CHAR(30) PRIMARY
KEY. address VARCHAR(256). presC#
INT FOREIGN KEY):
[C]CREATE TABLE Studio (name CHAR(30) PRIMARY
KEY. address VARCHAR(256). presC#
INT UNIQUE KEY REFERENCES MovieExec):
[D]CREATE TABLE Studio (name CHAR(30) PRIMARY
KEY. address VARCHAR(256). presC#
INT REFERENCES Movie Exec (cert#));
Choose the right statement B
[A]XML Schema allows us to declare simple types, such
as integer or float and even complex types
[B]All of the others
[C]XML schema provides us the ability to declare keys
and foreign keys.
[D]XML Schema is an alternative way to provide a
schema for XML documents.
, DBI202 Final Exam Questions & Answers
The relational operator that yields all possible pairs of C
rows from two tables is known as a _
[A]Union
[B]Selection
[C]Product
[D]Join
Consider a relation with schema R(A, B, CD) and FD's D
BC-> D, D-> A, A-> B. Which of the
following is the key of R?
[A]BD
[B]D
[C]AB
[D]BC
The ER Diagram uses three principle element types: D
[A]Entity sets. Constraints, and Relationships
[B]Entity sets. Attributes and Constraints
IC]Attributes. Constraints, and Relationships
[D]Entity sets. Attributes, and Relationships
In PSM. the difference between 3 stored procedure C
and a function is that
[A]A function has the return statement.
[B]We can declare local variables in a function.
[C]All of the others
[D]Loops are not allowed in a function.
Selecl Ihe right syntax for HAVING clause in SOL B
[A]
SELECT <list of attributes>
FROM <list of tables>
WHERE <conditions on tuples>
HAVING <conditions on groups>
GROUP BY <list of attributes>
[B]
SELECT <list of attributes>
FROM <list of tables>
WHERE <conditions on tuples>
GROUP BY <list of attributes>
HAVING <conditions on groups>
[C]
SELECT < list of attributes>
FROM < list of tables>
HAVING <conditions on groups>
WHERE <conditions on tuples>
GROUP BY <list of attributes>
[D]All of the others