Recent questions tagged databases

45 45 votes
2 answers 2 answers
11.0k
11.0k views
The following table refers to search items for a key in $B$-trees and $B^+$ trees.$$\begin{array}{|ll|ll|} \hline & \textbf {B-tree} & & \textbf {B}^+\text{-tree} \\\hl...
64 64 votes
6 answers 6 answers
30.3k
30.3k views
For relation R = (L, M, N, O, P), the following dependencies hold:$ M \rightarrow O,$ $NO \rightarrow P,$ $P \rightarrow L$ and $L \rightarrow MN$R is decomposed into R1 ...
47 47 votes
8 8 answers
11.5k
11.5k views
A university placement center maintains a relational database of companies that interview students on campus and make job offers to those successful in the interview. The...
85 85 votes
8 answers 8 answers
31.2k
31.2k views
From the following instance of a relation schema $R(A,B,C)$, we can conclude that:$$\begin{array}{|l|l|}\hline \textbf{A} & \textbf{B} & \textbf{C} \\\hline \text{1} & \...
73 73 votes
8 answers 8 answers
19.7k
19.7k views
Relation $R$ is decomposed using a set of functional dependencies, $F$, and relation $S$ is decomposed using another set of functional dependencies, $G$. One decompositio...
59 59 votes
8 answers 8 answers
24.9k
24.9k views
A $B^+$ - tree index is to be built on the Name attribute of the relation STUDENT. Assume that all the student names are of length $8$ bytes, disk blocks are of size $512...
51 51 votes
4 answers 4 answers
12.1k
12.1k views
With regards to the expressive power of the formal relational query languages, which of the following statements is true?Relational algebra is more powerful than relation...
80 80 votes
8 answers 8 answers
35.7k
35.7k views
Relation $R$ with an associated set of functional dependencies, $F$, is decomposed into $\text{BCNF}$. The redundancy (arising out of functional dependencies) in the resu...
14 14 votes
3 answers 3 answers
10.8k
10.8k views
We wish to construct a $B^+$ tree with fan-out (the number of pointers per node) equal to $3$ for the following set of key values:$80, 50, 10, 70, 30, 100, 90$Assume that...
22 22 votes
3 answers 3 answers
7.9k
7.9k views
Consider a relation examinee (regno, name, score), where regno is the primary key to score is a real number.Write a relational algebra using $( \Pi, \sigma, \rho, \times)...
86 86 votes
9 answers 9 answers
21.3k
21.3k views
Consider a relation geq which represents "greater than or equal to", that is, $(x,y) \in $ geq only if $y \geq x$.create table geq ( ib integer not null, ub integer not n...
62 62 votes
10 answers 10 answers
17.3k
17.3k views
Which of the following relational calculus expression is not safe?$\left\{t \mid \exists u \in R_1\left(t[A] = u[A]\right) \land \neg \exists s \in R_2 \left(t[A] = s[A]\...
188 188 votes
8 answers 8 answers
80.4k
80.4k views
$R(A,B,C,D)$ is a relation. Which of the following does not have a lossless join, dependency preserving $BCNF$ decomposition?$A \rightarrow B, B \rightarrow CD$$A \righta...
70 70 votes
3 answers 3 answers
13.7k
13.7k views
Let r and s be two relations over the relation schemes R and S respectively, and let A be an attribute in R. The relational algebra expression $\sigma_{A=a}(r \bowtie s)...
90 90 votes
5 answers 5 answers
15.5k
15.5k views
Suppose the adjacency relation of vertices in a graph is represented in a table Adj $(X,Y).$ Which of the following queries cannot be expressed by a relational algebra ex...
42 42 votes
4 answers 4 answers
15.8k
15.8k views
Consider a schema $R(A,B,C,D)$ and functional dependencies $A \rightarrow B$ and $C \rightarrow D$. Then the decomposition of R into $R_1 (A,B)$ and $R_2(C,D)$ isdependen...
14 14 votes
2 2 answers
4.5k
4.5k views
Consider a bank database with only one relation transaction (transno, acctno, date, amount)The amount attribute value is positive for deposits and negative for withdrawa...
20 20 votes
2 2 answers
7.4k
7.4k views
(a) Suppose you are given an empty $B^+$ tree where each node (leaf and internal) can store up to $5$ key values. Suppose values $1, 2,\ldots 10$ are inserted, in order, ...
89 89 votes
9 answers 9 answers
29.0k
29.0k views
In SQL, relations can contain null values, and comparisons with null values are treated as unknown. Suppose all comparisons with a null value are treated as false. Which ...
83 83 votes
5 answers 5 answers
26.1k
26.1k views
Given relations r(w, x) and s(y, z) the result ofselect distinct w, x from r, s is guaranteed to be same as r, provided.r has no duplicates and s is non-emptyr and s have...
50 50 votes
6 answers 6 answers
24.4k
24.4k views
Given the following relation instance.$$\begin{array}{|l|l|}\hline \text{X} & \text{Y} & \text{Z} \\\hline \text{1} & \text{4} & \text{2} \\ \text{1} & \text{5} & \te...
62 62 votes
4 answers 4 answers
22.9k
22.9k views
Given the relationsemployee (name, salary, dept-no), anddepartment (dept-no, dept-name,address),Which of the following queries cannot be expressed using the basic relatio...
67 67 votes
7 answers 7 answers
24.5k
24.5k views
B$^{+}$-trees are preferred to binary trees in databases becauseDisk capacities are greater than memory capacitiesDisk access is much slower than memory accessDisk data t...
6 6 votes
1 1 answer
1.6k
1.6k views
How is redundancy reduced in the following models?HierarchicalNetworkRelational
32 32 votes
6 answers 6 answers
6.4k
6.4k views
Suppose a database consist of the following relations:SUPPLIER (SCODE,SNAME,CITY). PART (PCODE,PNAME,PDESC,CITY). PROJECTS (PRCODE,PRNAME,PRCITY). SPPR (SCODE,PCODE,PRCOD...
100 100 votes
8 answers 8 answers
48.6k
48.6k views
Consider the following relational schemes for a library database:Book (Title, Author, Catalog_no, Publisher, Year, Price) Collection(Title, Author, Catalog_no)with the fo...
106 106 votes
4 answers 4 answers
31.1k
31.1k views
Let R and S be two relations with the following schema$R(\underline{P,Q}, R1, R2, R3)$$S(\underline{P,Q}, S1, S2)$where $\left\{P, Q\right\}$ is the key for both schemas....
72 72 votes
6 answers 6 answers
38.1k
38.1k views
A B-tree of order $4$ is built from scratch by $10$ successive insertions. What is the maximum number of node splitting operations that may take place?$3$$4$$5$$6$
43 43 votes
5 answers 5 answers
20.8k
20.8k views
A clustering index is defined on the fields which are of typenon-key and orderingnon-key and non-orderingkey and orderingkey and non-ordering
57 57 votes
7 answers 7 answers
24.7k
24.7k views
Which of the following tuple relational calculus expression(s) is/are equivalent to $\forall t \in r \left(P\left(t\right)\right)$?$\neg \exists t \in r \left(P\left(t\ri...