Professional Documents
Culture Documents
Questions OP1 OP2 OP3 OP4 AN SW ER S
Questions OP1 OP2 OP3 OP4 AN SW ER S
The
operation of
one Once a The state of
transaction transaction is database is the
What is isolation does not completed the same when it none 1
affect the results will ends as it
operation of persist begins
other
transaction
the smallest
can store any capable of
amount of either true or
A field is type of data storing many 3
data DBMS false
at any time facts
can store
Car
Which of the following is a valid Initials+fami
Student name registration Streetname 3
primary key field. ly name
number
Which of the following is a valid
database. 1. A telephone directory 2.
The northern college record system 3. 2 only 1 and 2 2 and 3 4 2
box of flowers 4.none
Is a special
Is a special
field that Is a special
field that has
identifies a field that each
A unique key field is to be a none 2
particular database has
unique
record in a data to have.
number
table
conceptual
Physical level is also known as internal level external level view level 1
level
.___________ is an association
Cardinality Mapping Relationship class 3
among several entities
Objects that contain the same types
of values and same methods are relations classes attributes tuples 2
grouped into
Which model(s) is(are) implementation
data model s
i)ER model
ii)Relational i only i and ii i ,ii and iii i ,ii ,iii and iv 1
iii.)Network
iv)Hierarchical model
relational
for any two
model for any two
tuples, the
supports tuples, the all tuples in a
values
A relation (from the relational multi-valued values particular
associated
database model) consists of a set of attributes associated with relation may 3
with one or
tuples, which implies that whose values all of their have different
more of their
can be attributes may attributes.
attributes
represented be the same.
must differ.
in sets.
Deciding the
What are the tasks which database To enter
Performance Graphical User
and/or delete Enhancing the
administrators may be called upon data in the monitoring and Interface (GUI) 2
maintenance necessary for SQL queries
to specifically perform? database
data entry
“Data Redundancy”
Colombo.
(ii) Total income of Glucorala has Statements Statements (i) Statements (i)
increased by 1.5% compared with that
of the previous year. (i) and (ii) and (iii) and (iv) Statement (i)
(iii) A. Chandran is a supplier to represent represent data represent data represents data
Glucorala and his email address is data while while while and the other
2
achan@yahoo.com. statements statements (ii) statements (ii) statements
(iv) A. Chandran had supplied 24% of (iii) and (iv) and (iv) and (iii) represent
the total sugar requirement of the
company.
represent represent represent information.
information. information. information.
Which of the following is a/are true
amount of time required
time required for the disk to
expected time to time required
in transferring rotate the
access a disk
data from/to activating a
Data transfer time refers to the address and sought-for 2
the disk
transfer a block read/write
to/from record under
of data. head.
primary the read-write
memory. head.
Physical data
Modification in physical level should Logical Data Conceptual
independenc none 1
not affect the logical level.This is independence Independence
e
Physical data
Modification in logical level should not Logical Data Conceptual
independenc none 2
affect the external level.This is independence Independence
e
It is the
It is an The collection
number of
association (or set) of None of the
What is degree of a Relation? attribute of its 1
relation
among two or similar above
more entities relationships
schema
It is the
It is an
number of The collection (or
None of the association
What is Relationship? attribute of its set) of similar 4
relation relationships above among two or
more entities
schema
The particular property which
describes the entity is called as
Integrity Table Database Attribute 4
Which language of database specifies SDL (Storage VDL (View DDL (Data Data Storage -
user views and their mappings to the Definition Definition Definition Definition 2
conceptual schema Language) Language) Language) Language
Query
Which translates DML statements in a DDL DML None of the
evaluation 3
query language? Interpreter Compiler above
engine
Which abstraction existing in the Physical
Logical level View level All the above 4
DBMS? level
The 'thing' in the real world with an
independent existence is called as. Entity set attributes degree entity 4
A database with single table Hierarchical Relational data Flat file Network data
3
structure is called a _________ data model model structure model
____________ data models are
Logical data Physical data Network data None of the
used to describe data at the lowest 2
model model model above
level.
Once the DBMS informs the user that
a transaction has successfully
completed, its effects should persist
even if the system crashes before all
its changes are reflected on disk. This
consistency isolation durability atomicity 3
property is called.
removes removes
is only
changes changes made
possible in results in
Aborting a transaction made so far in a transaction 2
Microsoft deadlock.
in the current after it has
Access.
transaction. committed
_________ is the person having
data base data base data base
central control over data and programs none. 3
accessing that data. manager designer administrator
the following are the roles of data base storage schema and
designer. schema structure and physical
all the above. 4
definition access method organization
definition modification
Provide
protection
Which of the following statement(s) is Allow
for data
(are) true for database management maintenance of Keep data and
against the programs
systems? high quality, that manipulate both a & b 4
unexpected
consistent and it together.
loss, damage
up to date data.
or
destruction.
Entities,
Entities and
The Entity Relation Model models Entities Relationships Relationships 4
Relationships
and Processes
a "thing"
which has a real physical
a real
either a real "thing" or a
physical
physical conceptual
"thing" that is any physical
existence "thing" that is
specific to a "thing" that
An entity is (e.g. a car or specific to a 1
particular exists in the
a student) or particular
database real world
a conceptual database
management
existence management
system
(e.g. a system
course)
An ER An ER model
An ER model is An ER model
model is concerned
concerned is entirely
provides a primarily with
primarily with concerned
Which of the following statements view of the a logical view
a physical with
best describes the function of an logic of the of the data and 1
implementation modeling the
entity relation model? data and not secondly with
of the data and physical
the physical the physical
secondly with implementatio
implementati implementatio
the logical view n
on n
._________ is a collection of
entity instances that are of same Entity Type Entity Value Entity Set none 3
type.
If every entity E1 of R participates
Total Partial Empty
with every other entity E2 of R then none 1
Participation Participation Participation
such a participation is
If some entity E1 of R participates
Total Partial Empty
with some other entity E2 of R then none 2
such a participation is Participation Participation Participation
When participating entity types are
not distinct in the relation ship Distant Recursive Iterative
none 2
types then such a relation ship is relationships relationship relationship
called
A key for which no subset is a Composite
Primary key Candidate key none 2
super key is called key
The following is an example of
name age Birth Date Phone no 4
multi valued attribute
Each relation
in a database There can be The sequence
Which of the following statements is Each row is
schema will multi-valued of columns is
correct, regarding a relation of the identified 3
relational model? not have a attributes in a not
uniquely.
unique a relation significant.
name.
Any multi-
valued
attributes
(also called A status of
The process of
repeating
Decomposing relations
groups) have transforming
relations with where any
been normalised
Which of the following is/are true with anomalies to partial
removed, so relations into 4
respect to denormalisation?
that there is a
produce smaller functional
well-structured unnormalised
single value at dependencies
relations physical record
the have been
intersection of specifications
removed.
each row and
column of the
table.
Provide a
Ability to deal
procedural
Facility to with
Supports language for
Which of the following is a (are) issue unstructured
aggregation query, data 1
feature(s) of the relational model? declarative data for CAD,
relationships. manipulation,
queries. CAM
definition and
applications.
control.
including updating, inserting, modifying
and retrieving data. a,b and c a,c ,d and e a,b and d b,d and e 1
The primary key cannot have null
value” .Which integrity rule Referential Entity Domain none 2
specifies this.
Foreign Key can be either a NULL
value or should be Primary Key value
of other relation.. Which integrity rule Referential Entity Domain none 1
specifies this.
a coherent set
a specific
defined by a of similar
type such as
entity type is__________ database objects that none 3
integer,text
integer,text etc. we want to
etc.
store data
by using __________modelling we
entity entity entity
can build the conceptual model of none 1
relationship representation integration
data
the degree of relation ship is also
power height depth cardinality 4
called as _________
E-R modelling technique is top-down bottom-up left-right right-left
1
_________ approach approach approach approach
which of the following are the conceptual visual
integrity both a & b 4
advantages of E-R model simplicity representation
strong entity weak entity
Err:508 small entity set none 3
set set
the number of attribute of a degree of a cardinality of a
both A & B none 1
relation schema is known as relation. relation.
__________is an association weak entity
entity set strong entity set relationship 4
among two or more entities set
___________ defines a set of
associations or a relationship set
. relation degree of the
among a given set of entity both A & B none 1
ship type relation
types.
structured programmed
procedural
.. relational algebra is ________ query query none 2
query language.
language language
Costings for
Transaction Support for the
The Data Dictionary provides future None of the
deadlock SQL interface 2
which of the following features? database above
detection. to the database
changes.
The process of combining entity
types from an ER diagram into a
specialise generalise consume assume 2
single relation in a relational
database is to
as a Many to
In a relation, an instance is stored
a Column a Row many as an index 2
as
relationship
Which one of the following is NOT data about includes user
self describing none 4
a characteristic of metadata? data data
_____________ is the
implementation independant list of logical conceptual
physical design none. 1
database objects (tables) that design design
represents the Conceptual model
A (non-key)
A key field that
A secondary A key field field in a table
matches a key
key field that exists that matches a
A foreign key is field in a 4
within a outside of the key field in a
second
table database second
(foreign) table
(foreign) table)
ensure that
ensure that a there are no
table that is transitional ensure that
in second dependencies, ensure that there are no
normal form i.e. to ensure the database dependencies
3 NF is designed to 2
is that there are conatins three between keys
decomposed no tables and foreign
into two or dependancies keys
more tables between non-
key fields.
ensure that
ensure that
every non ensure that a . ensure that a
every non key
key field in a table that is in table that is in
field in a
record has a first normal first normal
record is fully
Second Normal Form is designed to correspondin form is form is 4
functionaly
g foreign key decomposed decomposed
dependant
in at least into two or into two
upon the key
one other more tables tables
for that record.
table
a process
whereby the
design of a the process of a process
the process
table (relation) ensuring that whereby a
of ensuring
is decomposed a relational limit is put on
Normalization is that each 2
into more database has the number of
table has a
tables that more at least two fields a record
key
precisely fit the tables in it. can contain
relational
model
A
relationship A value in the
A value in the Two
between two database can
database can be attributes in
Which of the following is NOT an entity types be derived by
derived directly the database 4
example of data redundancy? can be performing a
from another have the same
derived from calculation on
value. value.
another other values.
relationship
a database
one that
that is able to
consists of
one that process the same as a
two or more
A relational database is consists of two tables, flat file 1
tables that
or more tables queries, database
are joined in
forms, reports
some way
and macros
is not allowed
is use only in a practical
is a way of Is a way of
when all of the implementatio
A many to many relationship (join) joining three joining two 4
tables is in third n of a
tables tables
normal form relational
design
not be used
in conjuction
only be based be based on a be based on a
with a set of
A query can directly on one set of other set of joined 4
joined
data table queries (related) tables
(related)
tables
ALL OF THE
OTHER
The primary characteristic of a key OPTION
A NAME TEXT UNIQUE 3
field as that it must be LISTED FOR
THIS
QUESTION
What kind of relationship exist
between customers and
salespersons if each customer may
one-to-one one to many many to many many to one 3
have one or more salespersons, and
each salesperson may have one or
more customers?
A relation R is said to be in
________________ if it is in BCNF
and there are non-trivial multi valued
1st NF 2nd NF 3rd NF 4th NF 4
dependencies
2ot
Entity- h1
is / are sample(s) of data model. Relational Rational None
relationship &
3
Joins An equality
between two join based on A table joined A Cartesian
The term “inner join” refers to: 2
tables in the one column with itself product join
same schema from each table
_____________ is a subquery
Related Correlated
which has reference to the main Both A & B None. 2
subquery subquery
query.
Using Using
What is the fastest way of accessing Using row id
Using JOINS correlates column id 4
a row in a table. constraints
subqueries constraints
State true or false, EXISTS,
cannot be data
SOME ,ANY are all operators in TRUE false 1
determined insufficient
SQL
What will be the output of the following
query.
SELECT REPLACE (TRANSLATE TROUBLET
THETROUBL THETHETR
(LTRIM( RTRIM( ’!! ATHEN !!’,’!’),’!’) HETROUBL NONE 1
’AN’,’***’),’*’,’TROUBLE’) FROM ETROUBLE OUBLE
E
DUAL;
displays
displays salary
salary of
of employees
what does the following query do. employees
and the null
SELECT SAL + and the null
values in the displays null
NVL(COMM,0) FROM EMP; values in the none. 1
commission values.
commission
column will not
column will
be replaced by
be replaced
0.
by 0.
The privilege
The privilege receiver is
receiver can given with the
what is the advantage of specifying grant the privileges
Both A & B. None. 1
grant option in the grant command. privileges to permanently
any other and the owner
user cannot revoke
them back
CREATETA CREATECOM
what command is used to create a
BLE as MAND AS . BOTH A NONE OF
table by copying the structure of 1
SELECT SELECT and B THE ABOVE
another table.
COMMAND TABLE
SELECT
SELECT
"table_name"
identify the correct syntax of "column_na
FROM both A & B none 1
SELECT statement me" FROM
"column_name
"table_name"
"
SELECT
SELECT
DISTINCT
DISTINCT SELECT
"table_name
"column_name DISTINCT
identify the correct syntax of "
" FROM none 2
DISTINCT clause FROM
FROM "table_name"
"column_na
"table_name"
me"
SELECT SELECT
SELECT
"column_nam "table_name"
"column_name"
e" FROM
FROM
identify the correct syntax of FROM "column_name
"table_name" none 1
WHERE clause "table_name"
WHERE
"
WHERE WHERE
"column_name"
"condition" "condition"
SELECT
"column_nam SELECT
e" "column_name"
FROM FROM
"table_name" "table_name"
identify the correct syntax of IN
WHERE WHERE both a & b none 1
operator. "column_nam "column_name"
e" IN ('value1', IN (value1,
'value2', ...) value2, ...)
SELECT SELECT
SELECT
"column_nam "column_name
"column_name"
e" "
FROM
FROM FROM
"table_name"
"table_name" "table_name"
identify the correct syntax of WHERE
WHERE WHERE none. 2
BETWEEN operator "column_nam
"column_name"
"table_name"
BETWEEN
e" BETWEEN BETWEEN
'value1' AND
value1 AND 'value1' AND
'value2'
value2 'value2'
SELECT
SELECT
"column_nam
"table_name"
e"
FROM
FROM
"column_name"
identify the correct syntax of LIKE "table_name"
WHERE both a & b none 1
operator WHERE
"column_name"
"column_nam
LIKE
e" LIKE
{PATTERN}
{PATTERN}
SELECT
"column_nam
SELECT
e" SELECT
"column_name
FROM "column_name"
"
"table_name" FROM
[WHERE
identify the correct syntax of [WHERE "table_name"
"condition"] none 1
ORDER BY clause "condition"] ORDER BY
ORDER BY
ORDER BY "column_name"
"column_name
"column_nam [ASC, DESC]
" [ASC, DESC]
e" [ASC,
DESC]
SELECT
COUNT("colu
SELECT
identify the correct syntax of mn_name")
COUNT FROM both a & b none 1
COUNT operator FROM
"table_name" "table_name"
SELECT
"column_na
me1", SELECT
SELECT
SUM("colum "column_name1" "column_name
n_name2") 1",
,
SUM("column_
identify the correct syntax of FROM SUM("column_n
name2") none 1
GROUP BY clause "table_name ame2")
FROM
" GROUP BY
"table_name"
GROUP BY "column_name1" GROUP BY
"column_na
me1"
SELECT SELECT
"column_na "column_name1" SELECT
me1", , "column_name
SUM("colum SUM("column_n 1",
n_name2") ame2") SUM("column_
FROM name2")
GROUP BY
identify the correct syntax of "table_name" FROM
"column_na none 2
HAVING clause. GROUP BY "table_name"
me1" "column_name1" HAVING
HAVING HAVING (arithematic
(arithematic (arithematic function
function function condition)
condition) condition)
CREATE
TABLE CREATE TABLE
"table_name" ("column 1"
("column 1" "data_type_for_c
"data_type_fo olumn_1",
identify the correct syntax for creating
r_column_1", "column 2" both a & b none 1
a table
"column 2" "data_type_for_c
"data_type_fo olumn_2",
r_column_2", ... )
... )
DELETE
identify the correct syntax for TABLE DROP TABLE DROP
none 2
deleting a table "table_name "table_name" "table_name"
"
INSERT INTO
"table_name" INSERT INTO
("column1",
"table_name"
identify the correct syntax for "column2", ...)
VALUES . both a & b none 1
inserting values into a table VALUES
("value1", ("value1",
"value2", ...) "value2", ...
its not
to add a column with not null dependent on
constraint the table should be empty non empty whether the none 1
________ table is empty
or not
its noe
to modify the data type of a the column dependent on
the column
column the prerequisite is should be whether the none 1
should be full
________ empty column is
empty or not
Grant
permission to
Amali,only to
retrieve data
Grant
from Grant
Consider the following SQL statement: permission to
Employee permission to
GRANT SELECT, Amali & Hiruni
table and
UPDATE(Designation) ON Employee Amali & Hiruni to update
grant
TO Amali,Hiruni WITH GRANT to retrieve designation of both b & c 4
permission to
OPTION; data from employees in
Hiruni, only to
What does this SQL statement do? Employee the Employee
update the
table. table.
designation
from
Employee
table
CREATE
ADD TABLE
TABLE
Which of the following SQL ALTER TABLE allows adding
defines a
command(s) is (are) correct with allows adding new tables to both a & b 4
new table
respect to database definitions? new columns. database at
with its
any time
columns.
displays
displays only
select job, count(*) from emp group displays only number of
number of none 2
by job jobs. employees
employees
under each job
which function is used to take end
Round() Ceil() Last_Day() Add_month() 3
date of the month
it places the
it groups the
rows in it places the
when we use group by in the SQL information
shadow page rows in order none 2
statement without using
and groups and then groups
the order
the data.
adding modifying
the ALTER TABLE comand lets creating new
integrity existing all the above 4
you columns
constraints columns
___________ allow developers to
build powerful commands out of sub queries double queries inner queries outer queries 1
simple ones
LIKE operator can be used by the
* _ % both b & c 4
following symbols
which function is used to trim
LTRIM SUBSTR RTRIM both a & c 4
specified characters from a string
multiple queries can be put together
and their output can be combined having where union group by 3
using ________ clause
the subquery which will execute
correlated complexed
once for each row returned by the sub queries nested queries 2
subqueries queries
outer query is
common
which of the following statements non unified procedural language for english like
3
are key features of SQL language language all relational language
databases
how is the execution of DQL query first row of last row of the middle row of
none 1
perform when it is having joins the tables tables the tables
It do not
Which of the following statements It increases There in no
reduce It minimizes
is/are correct regarding insertion zero normal 3
update redundancy
normalization? anomalies form relations
anomalies
(c) When too many joins are
a and b a,b and c b,c and d a nd c 2
necessary to access frequently used
What are the anomalies which can be
present due to un-normalised
relations?
(a) insertion
(b) selection a and b a,b and c a,c and d a nd c 3
(c) deletion
(d) update
(e) none
. Every
foreign key
No foreign key The tables
value must
should have a There should should be in
For referential integrity to be have a
corresponding be an index different 1
maintained correspondin
primary key on the tables schemas of the
g
value. database.
primary/uniq
ue key value
In a nested
Attributes of CREATE
SQL query, Join operation
different TABLE
Which of the following the results of can be used to
relations command can
statement(s) is (are) true for the the inner implement a 1
cannot have be used to
SQL relational query language? query is selection
the same create a virtual
passed to the operation
name relation
outer query
it counts only
when we pass a column as function it counts all it counts only it counts no
rows where 4
argument in COUNT() the rows even rows rows
row is not null.
data can be retrieved from data base
control manipulation definition query 4
using _________ language.
the output of the query floor(25.99)
26 25 25.5 26.5 2
from dual is
the output of the query
is cricket cricket cricket cricket is
concat( ’cricket’,concat(’is’,’religio cricket religion 4
religion is religion
n’)) from dual is
place the
which of the following correctly place the alias
alias at the both a & b
specifies how to indicate a column after each none 2
begining of will work
alias column
the column
A query
which
Used to retrieves
Used to join
What is a JOIN intersect two rows or None. 3
two tables
tables. columns from
multiple
tables.
To protect
some of the To hide To hide
what are the advantages of the
columns of a complexity of a complexity of all the above 4
views.
table from query. calculations.
other users.
if the view is it is not
if it has only
a view can be updated on what based on dependent on
one base none. 1
condition. columns in one the above
table.
or two tables conditions
To protect
some of the To hide To hide
Which of the following is not Occupies data
columns of a complexity of complexity of 2
correct about a View ? storage space
table from a query a calculation
other users
A view is not
A view is a updatable if it
A view can be
Which of the following statements single table is defined
derived from
is/are correct with respect to a view that is using all the above. 4
previously
in SQL? derived from grouping and
defined views
other tables aggregate
functions.
does not
Allow
Hide data does not Permit
Which of the following changing the
from the use of
statement(s) is (are) correct with unit of all the above 1
unauthorised derived
respect of external views? measurement
users. attributes.
of some
stored data.
replace alter
a sequence can be modified using alter table both 2 & 3 4
sequence sequence
we cant
drop delete remove
command to delete sequence remove a 1
sequence sequence sequence
sequence
during
during physical
when are indexes selected logical data both a & b neither a & b 2
data modelling
modelling
which of the following operations
Group By Having Distinct all 4
are not possible through a view
a view with a clustered index is
indexed hashed join clustered 1
called ___________
You can Views do not Views can be Views can be
Which of the following statements
create a index have permanent based on one dropped without 2
is not true about views? on view data or more tables dropping tables
Every view has a
A view is a Views do not None of the
What is not true about Views Query attached 4
virtual table contain data above
to it.
Do the view contain or view can data
yes no can’t say 2
store the data insufficient
data
Can a View based on another View yes no can’t say 1
insufficient
an optional structure associated
with a table to have direct access to
rows, which can be created to View Index synonym sequence 2
increase the performance of data
retrieval
What are the different type of
Segments
i) Data Segment ii)Index Segment i) and ii) and i),ii) and iii) i),ii), iii) and
i) , ii) only 4
iii)Rollback Segment iv) only only iv)
iv)Temporary Segment
Pre-defined
subsets of the
Occupy the disk All the views
Data integrity can be maintained by existing tables
space are updatable
Both b) and c) 4
/SQL
statements
Locks can be applicable for All of the
views indices triggers 3
__________ above
Ensure proper
minimize provided
The Advantages of the and meaning
storage optimum All the above 4
Normalization are redundancy flexibilities
full DML
operations
Reveals new
Which of the following is not true about Un-intentional Improved None of the
requirements in 3
the data dictionary query results
business
performance above
Is an
Can be Is accessed via
what is the mandatory condition fo integrated set Is stored in
maintained by vendor supplied 3
the transaction to be complete of system regular tables
the users views
tables
A rollback or
Obeys user
which of the following are the commit of
defined None of the
conditions to be satisfied by the Both a) and b) 3
integrity above
database objects transaction is
constraints
guaranteed
reduce
consume improve Query
Table means insert/update all the above 4
space performance performance
Hierarchical relational Network
RDBMS is based on none of these 2
model model model
Atomicity, Atomicity, Authority,
Consistency, Creativity, Consistency, None of the
ACID properties stands for Isolation and Isolation and Isolation and above
1
durability durability durability
Insert,
Insert, Update, Insert, Delete,
Find the valid DML statements Update, None 3
Modify Update
Erase
Primary key
used for
Which are the following statements It can’t identify It can uniquely
performing None 3
are true for primary key the row identify the row
check
constraints
Foreign key
used for Foreign key
Which are the following statements It can’t identify It can uniquely maps always to
performing 4
are true for foreign key the row identify the row a valid primary
check key
constraints
Capability to
Capability to Capability to
change the
Transaction control means manipulate commit or
structure of the
None 2
the database rollback
table
Column to
maintain Column to Column to be Column to be
Data integrity means 1
datatype maintain length not NULL unique
specifies
Parent may
Child having
What is not a feature of Child having Parent having have any
more than one 4
Hierarchical model a parent parent number of
parent
Childs
Doing Doing
Accessing
Access by sequential sequential
Data concurrency means multiple 2
multiple users multiple multiple
table records
deletes inserts
to remove the
to have least to have more
data
Normalization main important aim redundancy
redundancy flexible All the above 2
is between the
dependency on
primary key access
columns
To give more
To make all
To create as flexible access
To make data column
De-Normalization is required when redundancy many related in order to 1
dependency on tables avoid lengthy
primary key
joins
an approach
to data
management
the process of that stores a
creating small a methodology
stable data for documenting both data and representation
structures databases the of data as they
from complex illustrating the procedures would appear
A logical view is: 4
groups of data relationship acting on the to an
when between various data as application
designing a entities in the
relational database
objects that programmer or
database. can be user
automatically
retrieved and
shared