CS 292- Chapter 2

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

MCQ Question: We shall use the term _____________ to denote a candidate key that is chosen by the database designer as the principal means of identifying tuples within a relation. A. Superkey B. Candidate key C. Primary Key D. Foreign-key

Ans: Foreign-key Reference: Chapter 2 Page 44

MCQ Question: What is the null value? A. The null value is a special value that signifies that the value is unknown or does not exist B. The null value is a special value that is unrecognizable C. The null value is a field that contains spaces D. The null value is zero

Ans: A Reference: Chapter 2 Page 40

MCQ Question: A relational database consists of a collection of ? A. Tables B. Graphs C. Charts D. Information

Ans: A Reference: Chapter 2. Section 2.1. Page 37

MCQ Question: Which is the logical design of database? A. Database schema B. Database instance C. A & B D. None of above

Ans: A Reference: Page Ref: 41, Sec 2.2 Database schema

MCQ Question: What is join operation? A. a. Togather with Course_ ID B. b. Together with integer C. c. Together with friend D. Together with teacher ID

Ans: A Reference: page 52, section 2.6.5

MCQ Question: 6. Which of the following predicates satisfies the following statement: Instructors in Physics with a salary greater than $90,000 A. σ dept name =Physics salary>90000 (instructor) B. σ dept name =Physics salary>90000 (department) C. σ dept name =Physics salary<90000 (instructor) D. σ dept name =Physics salary>90000 (department)

Ans: A Reference: pg. 49, Section. 2.6.1 The Select Operation

MCQ Question: Query languages are categorized as A. Imperative B. Declarative C. Functional D. All of the above

Ans: All of the above Reference: Pg 47

MCQ Question: What is a unary operation? A. An operation that returns its argument relation with certain attributes left out. B. An operation that is performed on more than two relations. C. An operation that is performed on a pair of relations. D. An operation that is performed on one relation.

Ans: An operation that is performed on one relation. Reference: page 48, section 2.6

MCQ Question: In which query language does the user instruct the system to perform a specific sequence of operations on the database to compute the desired result? A. functional B. imperative C. declarative D. repetitive

Ans: B Reference: 2.5

MCQ Question: Which is a unary operation that returns its argument relation, with certain attributes left out? A. Select Operation B. Project Operation C. Product Opertion D. Join Operation

Ans: B Reference: Chapter Slides

MCQ Question: In a relational model, what term is used to refer to a row? A. Relation B. Tuple C. Attribute D. Domain

Ans: B Reference: Pg. 39. Section: Structure of Relational Databases

MCQ Question: Which key helps us identify a tuple in the relation? A. candidate key B. superkey C. primary key D. foreign key

Ans: B Reference: chapter -2, page -43, unit -2.3

MCQ Question: The union operation allows us to A. separate two relations B. combine two relations C. combine three relations D. separate three relations

Ans: B Reference: chapter 2 union operation

MCQ Question: ______ is used to refer to a row A. tuple B. attribute C. relation D. instance

Ans: B Reference: page 39

MCQ Question: What database schema along with primary key and foreign-key constraint can be depicted by which of the following? A. Referential integrity constraint B. Schema diagrams C. Referenced relation D. all of the above

Ans: B Reference: pg 46, section 2.4 schema diagrams

MCQ Question: Operations such as select, project and rename operation are known as which operation A. Cartesian B. Unary C. Union D. Binary

Ans: Binary Reference: page 48

MCQ Question: stores information about schemes, constraints, design decisions, usage standards and user information A. conceptual B. OLTP C. repository D. Data structures

Ans: C Reference: page 14

MCQ Question: A relational database is a collection of A. data B. relationships C. tables D. tuples

Ans: C Reference: page 37, paragraph 3

MCQ Question: What does relation schema consist of A. Values and attributes B. Corresponding domain and values C. Attribute and corresponding domain D. Value and domain

Ans: C Reference: page 41

MCQ Question: 4. A query language can be categorized as A. Imperative query language B. Functional query language C. All the Above D. None of the above

Ans: C Reference: page 47

MCQ Question: The key which denotes a candidate key that is chosen by the database designer as the principal means of identifying tuples within a relation is called a- A. Super key B. Foreign key C. Primary key D. None of the above

Ans: C Reference: page: 44, section: 2.3

MCQ Question: All of the below are basic operators except: A. set difference B. rename C. project D. set addition

Ans: D Reference: 2.11

MCQ Question: Which one is not the parts of a data model? A. Structure of the data B. Operations on the data C. Constraints on the data D. Codes in the data

Ans: D Reference: Ch 2.1.1 Page 17

MCQ Question: What is the difference between a database schema and a database instance? A. A database schema is the logical design of a database and the database instance is a foreign key used in a database. B. A database schema is the programming language used for a database and the database instance is a foreign key used in a database. C. A database schema is a snapshot of the data in the database at a given time and a database instance is the logical design of a database. D. A database schema is the logical design of a database and a database instance is a snapshot of the data in the database at a given time.

Ans: D Reference: page 41, section 2.2

MCQ Question: Which is not considered a specialized server. A. web server B. emails C. printer server D. phone number

Ans: D Reference: pg. 47

MCQ Question: Which answer is one of the two aspects of SQL? A. Data relation B. Data injection C. Data Manipulation D. Data Construction

Ans: Data Construction Reference: Ch 2.3 Page 29

T/F Question: Arity means to have unique attributes

Ans: False Reference: 2.22

T/F Question: In a functional query language, the user describes the desired information without giving a specific sequence of steps or function calls for obtaining that information.

Ans: False Reference: 2.5

T/F Question: The relational model gives us a single way to represent data: as a two-dimensional table called a schema.

Ans: False Reference: Ch 2.2 Page 21

T/F Question: Temporary tables, which are constructed by the SQL language processor when it performs its job of executing queries and data modifications. These relations are then kept in the database.

Ans: False Reference: Ch 2.3.1 Page 30

T/F Question: Database systems today typically dont support foreign-key constraints

Ans: False Reference: Chapter 2. Section 2.3 Page 46

T/F Question: The set-difference operation is denoted by +

Ans: False Reference: Chapter 2. Section 2.6.6. Page 55

T/F Question: The Cartesian-product operation (denoted by X) allows us to combine information from any one relations.

Ans: False Reference: From any two relations ( Chapter Slides)

T/F Question: The null value is a special value that signifies that the value is known or exists.

Ans: False Reference: Pg. 40. Section: Structure of Relational Databases

T/F Question: Cartesian product operation is denoted by r1 x r2

Ans: False Reference: chapter -2, page -60, unit-2.6.4

T/F Question: In the relational model, each row of a table contains data that represents an attribute of the entity. A composite key is made up of two or more attributes True

Ans: False Reference: page 15

T/F Question: Tuples or Attributes are not required for a relationship in the relational database model.

Ans: False Reference: page 39, paragraph 1

T/F Question: The concept of a "relation schema" corresponds to the programming-language notion of a variable, while the concept of a "relation" corresponds to the programming- language notion of type definition

Ans: False Reference: page 41

T/F Question: Two tuples in a relation are allowed to have exactly the same values for all attributes.

Ans: False Reference: page 43, section 2.3

T/F Question: Individual tuples in the relation are prohibited from having the same values on the key attributes at the same time.

Ans: False Reference: page 44

T/F Question: A domain is atomic if elements of the domain are considered to be divisible units.

Ans: False Reference: page: 40, section: 2.1

T/F Question: There is only one type of relation as part of the relational alegbra

Ans: False Reference: section 2.6.1, page 48

MCQ Question: Consist of a set of operations that take one or two relations as input and produce a new relation as their results A. Query language B. Equivalent queries C. Relational algebra D. Project operation

Ans: Project operation Reference: pp.48 (RELATIONAL ALGEBRA)

MCQ Question: Which relation is not recommended for the cartesian-product operation? A. Student age B. Instructor.ID C. Name D. Salary

Ans: Salary Reference: Page # 51, section 2.6.4

MCQ Question: The set of allowed values for each attribute is called the _____ of the attribute A. Null B. Query C. Domain D. Schema

Ans: Schema Reference: 2.5

MCQ Question: The relational algebra consists of a set of operations that take how many relation as input? A. One or Two B. Three or Four C. Five or Six D. Seven or Eight

Ans: Seven or Eight Reference: Chapter 2. Section 2.6. Page 48

Short Question: what schema is developed at this conceptual-design phase provides a detailed overview of the enterprise.

Ans: The designer reviews the schema to confirm that all data requirements are indeed satisfied and are not in conflict with one another.the designer must test the design to remove any unwanted features. The emphasis here is on defining the data and their relationships, rather than specifying the specifics of physical storage Reference: page 32

T/F Question: The Cartesian-product operation does not substract information from any two relations.

Ans: True Reference: 2.17

T/F Question: Cartesian product, and set difference, operate on pairs of relations and are therefore call binary operations.

Ans: True Reference: 2.6 section and 48 page number

T/F Question: A database schema, along with primary key and foreign-key constraints, can be depicted by schema diagrams.

Ans: True Reference: Chapter 2 Page 46

T/F Question: Database instance is a snapshot of the data in the database at a given instant in time.

Ans: True Reference: Chapter Slides

T/F Question: A query language is a language in which a user requests information from the database

Ans: True Reference: Page Ref: 47, Sec 2.5 Relational query language

T/F Question: The assignment operation denoted by â†

Ans: True Reference: Page Ref: 55, Sec 2.6.7 The assignment operation

T/F Question: The concept of relation schema corresponds to the programming language notion of type definition

Ans: True Reference: Pg 41

T/F Question: Attribute values are normally required to be atomic

Ans: True Reference: chapter 2 Attributes

T/F Question: Every cell in a relation can hold only a single value

Ans: True Reference: page 15

T/F Question: A relational database consists of a collection of tables, each of which is assigned a unique name.

Ans: True Reference: page 37, section 2.1

T/F Question: The domain of an attribute is the set of all possible values for that attribute.

Ans: True Reference: page 39, last paragraph

T/F Question: 3. A query language is a language in which a user requests information from the database. True or False.

Ans: True Reference: page 47

T/F Question: Query languages can be categorized as imperative, functional, or declarative.

Ans: True Reference: page 47

T/F Question: 5. The relational algebra consists of a set of operations that take one or two relations as input and produce a new relation as their result. True or False?

Ans: True Reference: page 48

T/F Question: The "Relational Algebra" defines a set of algebraic operations that operate on tables and outputs tables as their results.

Ans: True Reference: page 59

T/F Question: Does relational algebra consists of Operations that take one of two relations as input and produce a new relation as their result?

Ans: True Reference: pg 48, section 2.6

T/F Question: The description of a database is called the database schema

Ans: True Reference: pg. 34

T/F Question: Physical data independence is the capacity to change the internal schema without having to change the conceptual schema

Ans: True Reference: pg. 38

T/F Question: . A primary key is a candidate key chosen by the database designer as the principal means of identifying tuples within a relation

Ans: True Reference: pg. 44, Section. 2.3 Keys

T/F Question: The relational model remains the primary data model for commercial data-processing applications

Ans: True Reference: pp.37 (Introduction to the relational model)

T/F Question: In the structure of relational databases, attribute is referred to as column of a table

Ans: True Reference: section 2.1, page 39

MCQ Question: In a relational model, what term is used to refer to a column? A. Domain B. Relation C. Attribute D. Tuple

Ans: Tuple Reference: Pg. 39. Section: Structure of Relational Databases

MCQ Question: In the relational model, the term relation is used to refer to a: A. Table B. Row C. Column D. Values

Ans: Values Reference: page: 39, section: 2.1

MCQ Question: The Cartesian-product operation, donated by a cross (x) allows us to combine the information from how may relation? A. Two relations B. Three relations C. Five relations D. all of the above

Ans: all of the above Reference: pg 50, section 2.6.4

MCQ Question: What is the database instance? A. the specific type of data in a set of values B. it is a view of one piece of data in database C. it is a snapshot of the data in the database at a given instant in time D. all of the above

Ans: all of the above Reference: section 2.2, page 41

MCQ Question: Which is not considered a database system utilities. A. loading B. database storage reorganization C. web browsing D. backup

Ans: backup Reference: pg. 45

MCQ Question: What is these operation call select, project and rename operation ? A. a. unary B. b. binary C. c. project D. d. connect

Ans: d. connect Reference: 2.6, page # 48

MCQ Question: data independence changes the conceptual scheme without changing the external scheme. A. logical B. physica C. DDL D. data view

Ans: data view Reference: page 14

MCQ Question: Which constraint requires that the values appearing in specified attributes of any tuple in the referencing relation also appear in specified attributes of at least one tuple in the referenced relation? A. foreign-key B. primary-key C. referential integrity D. none of the above

Ans: none of the above Reference: 2.3

MCQ Question: What is simply sequence of values? A. tuple B. relation C. attribute D. none of the above

Ans: none of the above Reference: chapter 2, page -39, unit-2.3

MCQ Question: ______ is a set of one or more attributes that, taken collectively, allows us to identify uniquely a tuple in the relation. A. candidate key B. primary key C. superkey D. none of the above

Ans: none of the above Reference: page 44

MCQ Question: Which is an example of a select operation ? A. instructor X teaches B. ^(and), (or) , (not) C. ID, name, salary (instructor) D. x (E)

Ans: x (E) Reference: Chapter slides

MCQ Question: To denote rename operator we use the lowercase letter A. σ B. Î C. s D. Ï

Ans: Ï Reference: Page Ref: 56, Sec 2.6.8 Rename operation

Short Question: Based on the following query: σdept name=“Physicsâ€(instructor ⋈instructor.ID=teaches.ID teaches) Provide an alternative query that provides the same result on any database

Ans:(σdept name=“Physicsâ€(instructor)) ⋈instructor.ID=teaches.ID teaches Reference: pg. 58, Section 2.6.9 Equivalent Queries

Short Question: Describe a relation, a tuple, and an attribute.

Ans:A relation refers to a table, a tuple refers to a row, and an attribute refers to the column in a table. Reference: page 39, section 2.1

Short Question: Whats the difference of a data dictionary utility to database management system (DBMS)

Ans:Data dictionary includes a wider variety of information and is accessed mainly by users rather than by the DBMS software. Reference: pg. 46

Short Question: 8. What is imperative query language?

Ans:In an imperative query language, the user instructs the system to perform a specific sequence of operations on the database to compute the desired result; such languages usually have a notion of state variables, which are updated in the course of the computation. Reference: chapter -2, page -47, unit -2.5

Short Question: What is Relational-Algebra expression?

Ans:It is operations into relational algebra expression is as like composing arithmetic operations. Reference: pg 50, section 2.6.3.

Short Question: name some "pure" languages

Ans:Relational algebra, tuple relational calculus, domain relational calculus Reference: chapter 2 Relational Query Languages

Short Question: How does The Assignment Operation works ?

Ans:The assignment operator usually returns a reference to the object so as to be used in multiple assignments made in a single statement such as "a=b=c", where a, b and c are operands. The assignment operator expects the type of both the left- and right-hand side to be the same for successful assignment. Reference: https:##www.geeksforgeeks.org#assignment-operators-in-c-c#

Short Question: What operation allows us to produce ID, name, and salary?

Ans:The project operation. Reference: page 49, section 2.6.2

Short Question: What does the relational data model include?

Ans:The relational data model is based on a collection of tables. The user of the database system may query these tables, insert new tuples, delete tuples, and up- date (modify) tuples. There are several languages for expressing these operations. Reference: Pg 58

Short Question: What is the relational data model based on?

Ans:The relational model is based on a collection of tables where the user of the database system may query these tables, insert new tuples, delete tuples, and update tuples. Reference: 2.1

Short Question: Give atleast 5 basic operations on relational algebra

Ans:The six basic operations are: select, project, union, set difference, cartesian product, and rename Reference: 2.11

Short Question: Name the three categories of query languages and give a brief description.

Ans:The three categories of query languages are **imperative, functional, and declarative**. In an **imperative** **query language**, the user instructs the system to perform a specific sequence of operations on the database to compute the desired result. In a **functional query language**, the computation is expressed as the evaluation of functions that may operate on data in the database or on the results of other functions. In a **declarative query language**, the user describes the desired information without giving a specific sequence of steps or function calls for obtaining that information. Reference: page 47

Short Question: Why are set operations important in relational algebra?

Ans:The various types of set operations are important in relational algebra, and the database system in general, because it permits the results of different inquiries to be consolidated into a solitary outcome set. An example would be a set table with the ID, name, department name, and salary. In addition, which each and very set it has its own essential function which is useful. The various types of sets include (select, project, and e Cartesian-product operation.) Reference: section 2.6.3, page 50

Short Question: Which are the different kind of keys in the relational models?

Ans:Three different kind of keys are there in the relational models, superkey, candidate keys, and primary key. Reference: Page # 43, section 2.3

Short Question: What are the ways of declaring an attribute or set of attributes to be a key on the CREATE TABLE statement that defines a stored relation?

Ans:We may declare one attribute to be a key when that attribute is listed in the relation schema. We may add to the list of items declared in the schema. Reference: Ch 2.3.6 Page 34

Short Question: Define what is primary key?

Ans:We use the term primary key to denote a candidate key that is chosen by the database designer as the principal means of identifying tuples within a relation. Reference: pp.44 (KEYS)

Short Question: What does it mean when a domain is atomic?

Ans:When the domain is atomic. it means that, each entry is treated as a single indivisible unit. Reference: page 40 paragraph 1


संबंधित स्टडी सेट्स

Principles of Managerial Accounting - Chapter 22 Test

View Set

Mastering Biology Ch. 10 (Cell Respiration)

View Set

India's Foreign Policy: Retrospect and Prospect

View Set

Cloud App Development - Cloud Computing Environments

View Set

Understanding Business Chapter 8

View Set