Explore topic-wise MCQs in Computer Science Engineering (CSE).

This section includes 175 Mcqs, each offering curated multiple-choice questions to sharpen your Computer Science Engineering (CSE) knowledge and support exam preparation. Choose a topic below to get started.

1.

An ________ is a set of entities of the same type that share the same properties, or attributes.

A. Entity set
B. Attribute set
C. Relation set
D. Entity model
Answer» B. Attribute set
2.

The attribute name could be structured as an attribute consisting of first name, middle initial, and last name. This type of attribute is called

A. Simple attribute
B. Composite attribute
C. Multivalued attribute
D. Derived attribute
Answer» C. Multivalued attribute
3.

create table apartment(ownerID varchar (5), ownername varchar(25), floor numeric(4,0),primary key (ownerID:));Choose the correct option regarding the above statement

A. The statement is syntactically wrong
B. It creates a relation with three attributes ownerID, ownername, floor in which floor cannot be null.
C. It creates a relation with three attributes ownerID, ownername, floor in which ownerID cannot be null.
D. It creates a relation with three attributes ownerID, ownername, floor in which ownername must consist of at least 25 characters.
Answer» D. It creates a relation with three attributes ownerID, ownername, floor in which ownername must consist of at least 25 characters.
4.

In a relation between the entities the type and condition of the relation should be specified. That is called as______attribute.

A. Desciptive
B. Derived
C. Recursive
D. Relative
Answer» B. Derived
5.

With SQL, how do you select all the records from a table named Persons where the value of the column FirstName ends with an a ?

A. SELECT * FROM Persons WHERE FirstName= a
B. SELECT * FROM Persons WHERE FirstName LIKE a%
C. SELECT * FROM Persons WHERE FirstName LIKE %a
D. SELECT * FROM Persons WHERE FirstName= %a%
Answer» D. SELECT * FROM Persons WHERE FirstName= %a%
6.

If you don t specify ASC or DESC after a SQL ORDER BY clause, the following is used by default ______________

A. ASC
B. DESC
C. There is no default value
D. None of the mentioned
Answer» B. DESC
7.

With SQL, how can you return all the records from a table named Persons sorted descending by FirstName ?

A. SELECT * FROM Persons SORT BY FirstName DESC
B. SELECT * FROM Persons ORDER FirstName DESC
C. SELECT * FROM Persons SORT FirstName DESC
D. SELECT * FROM Persons ORDER BY FirstName DESC
Answer» E.
8.

Which of the following command makes the updates performed by the transaction permanent in the database?

A. ROLLBACK
B. COMMIT
C. TRUNCATE
D. DELETE
Answer» C. TRUNCATE
9.

Which question corresponds best to the following query? SELECT CID, CDUR - 1,' = PRICE' FROM COURSES ORDER BY 2

A. Select three columns from the COURSES table, of which the third one has a constantvalue, i.e. = PRICE . Leave an empty line after every second line.
B. Select two columns from the COURSES table, the second one gets as title =PRICE .Sort the data according to the second column, in ascending order.
C. Select three columns from the COURSES table, of which the third one has a constantvalue, i.e. = PRICE . Sort the data according to the second column, in ascending order.
D. Select two columns from the COURSES table, of which the second one has a constantvalue, i.e. = PRICE . Sort the data according to the second column, in ascending order
Answer» D. Select two columns from the COURSES table, of which the second one has a constantvalue, i.e. = PRICE . Sort the data according to the second column, in ascending order
10.

An entity set that does not have sufficient attributes to form a primary key is termed a __________

A. Strong entity set
B. Variant set
C. Weak entity set
D. Variable set
Answer» D. Variable set
11.

For each attribute of a relation, there is a set of permitted values, called the ________ of that attribute.

A. Domain
B. Relation
C. Set
D. Schema
Answer» B. Relation
12.

Database __________ which is the logical design of the database, and the database _______ which is a snapshot of the data in the database at a given instant in time.

A. Instance, Schema
B. Relation, Schema
C. Relation, Domain
D. Schema, Instance
Answer» E.
13.

Course(course_id,sec_id,semester) Here the course_id,sec_id and semester are __________ and course is a _________

A. Relations, Attribute
B. Attributes, Relation
C. Tuple, Relation
D. Tuple, Attributes
Answer» C. Tuple, Relation
14.

Department (dept name, building, budget) and Employee (employee_id, name, dept name, salary) Here the dept_name attribute appears in both the relations. Here using common attributes in relation schema is one way of relating ___________ relations.

A. Attributes of common
B. Tuple of common
C. Tuple of distinct
D. Attributes of distinct
Answer» D. Attributes of distinct
15.

State true or false: If a relation consists of a foreign key, then it is called a referenced relation of the foreign key dependency.

A. True
B. False
C. none
D. all
Answer» C. none
16.

Statement 1: A tuple is a row in a relation Statement 2: Existence of multiple foreign keys in a same relation is possible

A. Both the statements are true
B. Statement 1 is correct but Statement 2 is false
C. Statement 1 is false but Statement 2 is correct
D. Both the statements are false
Answer» B. Statement 1 is correct but Statement 2 is false
17.

Choose the option that correctly explains in words, the function of the following relational algebra expression year 2009 (book borrow)

A. Selects all tuples from the Cartesian product of book and borrow
B. Selects all the tuples from the natural join of book and borrow wherever the year is lesser than 2009
C. Selects all the tuples from the natural join of book and student wherever the year is greater than or equal to 2009
D. Selects all tuples from the Cartesian product of book and borrow wherever the year is greater than or equal to 2009
Answer» C. Selects all the tuples from the natural join of book and student wherever the year is greater than or equal to 2009
18.

What is the syntax to load data into the database? (Consider D as the database and a, b, c as datA:)

A. enter into D (a, b, C:);
B. insert into D values (a, b, C:);
C. insert into D (a, b, C:);
D. insert (a, b, C:) values into D;
Answer» C. insert into D (a, b, C:);
19.

If a1, a2, a3 are attributes in a relation and S is another relation, which of the following is an incorrect specification of an integrity constraint?

A. primary key(a1, a2, a3)
B. primary key(a1)
C. foreign key(a1, a2) references S
D. foreign key(a1, a2)
Answer» E.
20.

A le produced by a spreadsheet

A. is generally stored on disk in an ascii text format
B. can be used as is by the dbms
C. all of the mentioned
D. none of the mentioned
Answer» B. can be used as is by the dbms
21.

Find the names of these cities with temperature and condition whose condition is neither sunny nor cloudy.

A. SELECT city, temperature, condition FROM weather WHERE condition NOT IN ( sunny , cloudy )
B. SELECT city, temperature, condition FROM weather WHERE condition NOT BETWEEN ( sunny , cloudy )
C. SELECT city, temperature, condition FROM weather WHERE condition IN ( sunny , cloudy )
D. SELECT city, temperature, condition FROM weather WHERE condition BETWEEN ( sunny , cloudy );
Answer» B. SELECT city, temperature, condition FROM weather WHERE condition NOT BETWEEN ( sunny , cloudy )
22.

What type of join is needed when you wish to include rows that do not have matching values?

A. Equi-join
B. Natural join
C. Outer join
D. All of the Mentioned
Answer» D. All of the Mentioned
23.

Find all the cities with temperature, condition and humidity whose humidity is in the range of 63 to 79.

A. SELECT * FROM weather WHERE humidity IN (63 to 79)
B. SELECT * FROM weather WHERE humidity NOT IN (63 AND 79)
C. SELECT * FROM weather WHERE humidity BETWEEN 63 AND 79
D. SELECT * FROM weather WHERE humidity NOT BETWEEN 63 AND 79
Answer» D. SELECT * FROM weather WHERE humidity NOT BETWEEN 63 AND 79
24.

The following SQL is which type of join: SELECT CUSTOMER_T. CUSTOMER_ID, ORDER_T. CUSTOMER_ID, NAME, ORDER_ID FROM CUSTOMER_T,ORDER_T WHERE CUSTOMER_T. CUSTOMER_ID = ORDER_T. CUSTOMER_ID?

A. Equi-join
B. Natural join
C. Outer join
D. Cartesian join
Answer» B. Natural join
25.

The following SQL is which type of join: SELECT CUSTOMER_T. CUSTOMER_ID, ORDER_T. CUSTOMER_ID, NAME, ORDER_ID FROM CUSTOMER_T,ORDER_T?

A. Equi-join
B. Natural join
C. Outer join
D. Cartesian join
Answer» E.
26.

___________ is the collection of memory structures and Oracle background processes that operates against an Oracle database.

A. Database
B. Instance
C. Tablespace
D. Segment
Answer» C. Tablespace
27.

Relational schemas and other metadata about relations are stored in a structure called the ____________

A. Metadata
B. Catalog
C. Log
D. Data Dictionary
Answer» E.
28.

A relational database system needs to maintain data about the relations, such as the schema of the relations. This is called

A. Metadata
B. Catalog
C. Log
D. Dictionary
Answer» B. Catalog
29.

__________ is a contiguous group of blocks allocated for use as part of a table, index, and so forth.

A. Tablespace
B. Segment
C. Extent
D. Block
Answer» D. Block
30.

A ________ is a logical grouping of database objects, usually to facilitate security, performance, or the availability of database objects such as tables and indexes.

A. Tablespace
B. Segments
C. Extents
D. Blocks
Answer» B. Segments
31.

An Oracle __________ is a set of tables and views that are used as a read-only reference about the database.

A. Database dictionary
B. Dictionary table
C. Data dictionary
D. Dictionary
Answer» D. Dictionary
32.

Indices whose search key specifies an order different from the sequential order of the file are called ___________ indices.

A. Nonclustered
B. Secondary
C. All of the mentioned
D. None of the mentioned
Answer» D. None of the mentioned
33.

The database design that consists of multiple tables that are linked together through matching data stored in each table is called

A. Hierarchical database
B. Network database
C. Object oriented database
D. Relational database
Answer» E.
34.

In ordered indices the file containing the records is sequentially ordered, a ___________ is an index whose search key also defines the sequential order of the file.

A. Clustered index
B. Structured index
C. Unstructured index
D. Nonclustered index
Answer» B. Structured index
35.

An ____________ consists of a search-key value and pointers to one or more records with that value as their search-key value.

A. Index entry
B. Index hash
C. Index cluster
D. Index map
Answer» B. Index hash
36.

The traditional storage of data that is organized by customer, stored in separate folders in filing cabinets is an example of what type of database system?

A. Hierarchical
B. Network
C. Object oriented
D. Relational
Answer» B. Network
37.

In a _______ clustering index, the index record contains the search-key value and apointer to the first data record with that search-key value and the rest of the records will be inthe sequential pointers.

A. Dense
B. Sparse
C. Straight
D. Continuous
Answer» B. Sparse
38.

Incase the indices values are larger, index is created for these values of the index. This is called

A. Pointed index
B. Sequential index
C. Multilevel index
D. Multiple index
Answer» D. Multiple index
39.

A search key containing more than one attribute is referred to as a _________ search key.

A. Simple
B. Composite
C. Compound
D. Secondary
Answer» C. Compound
40.

Insertion of a large number of entries at a time into an index is referred to as __________ of the index.

A. Loading
B. Bulk insertion
C. Bulk loading
D. Increase insertion
Answer» D. Increase insertion
41.

While inserting the record into the index, if the search-key value does not appear in the index.

A. The system adds a pointer to the new record in the index entry
B. The system places the record being inserted after the other records with the same searchkey values
C. The system inserts an index entry with the search-key value in the index at the appropriate position
D. None of the mentioned
Answer» D. None of the mentioned
42.

Which of the following schemas does define a view or views of the database for particular users?

A. Internal schema
B. Conceptual schema
C. Physical schema
D. External schema
Answer» E.
43.

Which of the following are the process of selecting the data storage and data access characteristics of the database?

A. Logical database design
B. Physical database design
C. Testing and performance tuning
D. Evaluation and selecting
Answer» C. Testing and performance tuning
44.

Which of the following terms does refer to the correctness and completeness of the data in a database?

A. Data security
B. Data constraint
C. Data independence
D. Data integrity
Answer» E.
45.

If the state of the database no longer reflects a real state of the world that the database is supposed to capture, then such a state is called

A. Consistent state
B. Parallel state
C. Durable state
D. Inconsistent state
Answer» E.
46.

For select operation the ________ appear in the subscript and the ___________ argument appears in the paranthesis after the sigmA:)

A. Predicates, relation
B. Relation, Predicates
C. Operation, Predicates
D. Relation, Operation
Answer» B. Relation, Predicates
47.

The relation with the attribute which is the primary key is referenced in another relation. The relation which has the attribute as a primary key is called ______________

A. Referential relation
B. Referencing relation
C. Referenced relation
D. Referred relation
Answer» D. Referred relation
48.

Relational Algebra is a __________ query language that takes two relations as input and produces another relation as an output of the query.

A. Relational
B. Structural
C. Procedural
D. Fundamental
Answer» D. Fundamental
49.

The ___________ operation, denoted by , allows us to find tuples that are in one relation but are not in another.

A. Union
B. Set-difference
C. Difference
D. Intersection
Answer» C. Difference
50.

Consider attributes ID, CITY and NAME. Which one of this can be considered as a super key?

A. NAME
B. ID
C. CITY
D. CITY, ID
Answer» C. CITY