Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Filter
Profile
Wall
Recent activity
All questions
All answers
Exams Taken
All Blogs
Answers by Aravind
1
votes
1
GATE CSE 1993 | Question: 27
Draw the state transition of a deterministic finite state automaton which accepts all strings from the alphabet $\{a,b\}$, such that no string has $3$ consecutive occurrences of the letter $b$.
Draw the state transition of a deterministic finite state automaton which accepts all strings from the alphabet $\{a,b\}$, such that no string has $3$ consecutive occurre...
13.0k
views
answered
Oct 18, 2014
Theory of Computation
gate1993
theory-of-computation
finite-automata
easy
descriptive
+
–
7
votes
2
GATE CSE 1991 | Question: 12-a
Suppose a database consist of the following relations: SUPPLIER (SCODE,SNAME,CITY). PART (PCODE,PNAME,PDESC,CITY). PROJECTS (PRCODE,PRNAME,PRCITY). SPPR (SCODE,PCODE,PRCODE,QTY). Write SQL programs corresponding to the following queries: Print PCODE values for ... part to a project in the second city, but do not print the triples in which the two CITY values are same.
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...
3.4k
views
answered
Oct 4, 2014
Databases
gate1991
databases
sql
normal
descriptive
+
–
112
votes
3
GATE CSE 2014 Set 1 | Question: 22
Given the following statements: S1: A foreign key declaration can always be replaced by an equivalent check assertion in SQL. S2: Given the table $R(a,b,c)$ where $a$ and $b$ together form the primary key, the following is a valid table definition. CREATE ... S1 is TRUE and S2 is FALSE Both S1 and S2 are TRUE S1 is FALSE and S2 is TRUE Both S1 and S2 are FALSE
Given the following statements: S1: A foreign key declaration can always be replaced by an equivalent check assertion in SQL. S2: Given the table $R(a,b,c)$ where $a$ an...
23.6k
views
answered
Oct 2, 2014
Databases
gatecse-2014-set1
databases
normal
sql
+
–
5
votes
4
GATE CSE 2006 | Question: 67
Consider the relation account (customer, balance) where the customer is a primary key and there are no null values. We would like to rank customers according to decreasing balance. The customer with the largest balance gets rank $1.$ Ties are not broke but ranks are skipped: if ... of the above statements are correct? $2$ and $5$ $1$ and $3$ $1$ and $4$ $3$ and $5$
Consider the relation account (customer, balance) where the customer is a primary key and there are no null values. We would like to rank customers according to decreasin...
21.2k
views
answered
Oct 1, 2014
Databases
gatecse-2006
databases
sql
normal
+
–
48
votes
5
GATE CSE 2014 Set 1 | Question: 30
Given the following two statements: S1: Every table with two single-valued attributes is in $\text{1NF, 2NF, 3NF}$ and $\text{BCNF}.$ S2: $AB \to C, D \to E, E \to C$ ... is CORRECT? S1 is TRUE and S2 is FALSE. Both S1 and S2 are TRUE. S1 is FALSE and S2 is TRUE. Both S1 and S2 are FALSE.
Given the following two statements: S1: Every table with two single-valued attributes is in $\text{1NF, 2NF, 3NF}$ and $\text{BCNF}.$ S2: $AB \to C, D \to E, E \to C$ is ...
12.4k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set1
databases
database-normalization
normal
+
–
–4
votes
6
GATE CSE 2014 Set 1 | Question: 54
Given the following schema: employees(emp-id, first-name, last-name, hire-date, dept-id, salary) departments(dept-id, dept-name, manager-id, location-id) You want to display the last names and hire dates of all latest hires in their ... of pairwise comparison. It generates an error because of the GROUP BY clause cannot be used with table joins in a sub-query.
Given the following schema: employees(emp-id, first-name, last-name, hire-date, dept-id, salary) departments(dept-id, dept-name, manager-id, location-id)You wan...
14.6k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set1
databases
sql
normal
+
–
–6
votes
7
GATE CSE 2014 Set 2 | Question: 21
The maximum number of superkeys for the relation schema $R(E,F,G,H)$ with $E$ as the key is _____.
The maximum number of superkeys for the relation schema $R(E,F,G,H)$ with $E$ as the key is _____.
11.6k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set2
databases
numerical-answers
easy
candidate-key
+
–
47
votes
8
GATE CSE 2014 Set 2 | Question: 22
Given an instance of the STUDENTS relation as shown as below ... $(\text{StudentName, StudentAge})$ to be a key for this instance, the value $X$ should NOT be equal to______.
Given an instance of the STUDENTS relation as shown as below$$\begin{array}{|c|c|c|c|c|} \hline \textbf {StudentID} & \textbf{StudentName} & \textbf{StudentEmail} & \text...
7.3k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set2
databases
numerical-answers
easy
candidate-key
+
–
–1
votes
9
GATE CSE 2014 Set 2 | Question: 30
Consider a join (relation algebra) between relations $r(R)$ and $s(S)$ using the nested loop method. There are $3$ ... $s(S)$ is more than $0.5$. join selection factor between $r(R)$ and $s(S)$ is less than $0.5$.
Consider a join (relation algebra) between relations $r(R)$ and $s(S)$ using the nested loop method. There are $3$ buffers each of size equal to disk block size, out of w...
20.9k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set2
databases
normal
joins
+
–
–5
votes
10
GATE CSE 2014 Set 2 | Question: 54
SQL allows duplicate tuples in relations, and correspondingly defines the multiplicity of tuples in the result of joins. Which one of the following queries always gives the same answer as the nested query shown below: select * from R where a in (select S.a from S) select R. ... a from S) as S1 where R.a=S1.a select R.* from R,S where R.a=S.a and is unique R
SQL allows duplicate tuples in relations, and correspondingly defines the multiplicity of tuples in the result of joins. Which one of the following queries always gives t...
19.6k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set2
databases
sql
normal
+
–
50
votes
11
GATE CSE 2014 Set 3 | Question: 21
What is the optimized version of the relation algebra expression $\pi_{A1}(\pi_{A2}(\sigma_{F1}(\sigma_{F2}(r))))$, where $A1, A2$ are sets of attributes in $r$ with $A1 \subset A2$ and $F1,F2$ are Boolean expressions based on the attributes in $r$ ... $\pi_{A2}(\sigma_{(F1 \wedge F2)}(r))$ $\pi_{A2}(\sigma_{(F1 \vee F2)}(r))$
What is the optimized version of the relation algebra expression $\pi_{A1}(\pi_{A2}(\sigma_{F1}(\sigma_{F2}(r))))$, where $A1, A2$ are sets of attributes in $r$ with $A1...
10.8k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set3
databases
relational-algebra
easy
+
–
–6
votes
12
GATE CSE 2014 Set 3 | Question: 22
A prime attribute of a relation scheme $R$ is an attribute that appears in all candidate keys of $R$ in some candidate key of $R$ in a foreign key of $R$ only in the primary key of $R$
A prime attribute of a relation scheme $R$ is an attribute that appearsin all candidate keys of $R$in some candidate key of $R$in a foreign key of $R$only in the primary ...
13.3k
views
answered
Oct 1, 2014
Databases
gatecse-2014-set3
databases
easy
candidate-key
+
–
18
votes
13
GATE CSE 1993 | Question: 23
The following relations are used to store data about students, courses, enrollment of students in courses and teachers of courses. Attributes for primary key in each relation are marked by *'. Students (rollno*, sname, saddr) courses (cno*, ... name of students who got A grade in at least one course taught by teacher names Ramesh for the above relational database.
The following relations are used to store data about students, courses, enrollment of students in courses and teachers of courses. Attributes for primary key in each rela...
3.9k
views
answered
Oct 1, 2014
Databases
gate1993
databases
sql
relational-calculus
normal
descriptive
+
–
0
votes
14
GATE CSE 2014 Set 3 | Question: 30
Consider the relational schema given below, where eId of the relation dependent is a foreign key referring to empId of the relation employee. Assume that every employee has at least one associated dependent in the dependent relation. employee (empId, ... is greater than that of some dependent. all dependents. some of his/her dependents. all of his/her dependents.
Consider the relational schema given below, where eId of the relation dependent is a foreign key referring to empId of the relation employee. Assume that every employee h...
13.7k
views
answered
Sep 30, 2014
Databases
gatecse-2014-set3
databases
relational-algebra
normal
+
–
19
votes
15
GATE CSE 2014 Set 3 | Question: 54
Consider the following relational schema: employee (empId,empName,empDept) customer (custId,custName,salesRepId,rating) salesRepId is a foreign key referring to empId of the employee relation. Assume that each employee makes a sale to at least one ... a 'GOOD' rating. Names of all the employees with all their customers having a 'GOOD' rating.
Consider the following relational schema:employee (empId,empName,empDept) customer (custId,custName,salesRepId,rating) salesRepId is a foreign key referring to empId of t...
16.6k
views
answered
Sep 30, 2014
Databases
gatecse-2014-set3
databases
sql
easy
+
–
48
votes
16
GATE CSE 2012 | Question: 43
Suppose $R_{1} (\underline{A}, B)$ and $R_{2} (\underline{C}, D) $ are two relation schemas. Let $r_{1}$ and $r_{2}$ be the corresponding relation instances. $B$ is a foreign key that refers to $C$ in $R_{2}$. If data in $r_{1}$ and $r_{2}$ satisfy referential ... $\prod_{B}(r_{1}) = \prod _{C}(r_{2})$ $\prod_{B}(r_{1}) - \prod _{C}(r_{2}) \neq \varnothing$
Suppose $R_{1} (\underline{A}, B)$ and $R_{2} (\underline{C}, D) $ are two relation schemas. Let $r_{1}$ and $r_{2}$ be the corresponding relation instances. $B$ is a for...
11.3k
views
answered
Sep 30, 2014
Databases
gatecse-2012
databases
relational-algebra
normal
+
–
36
votes
17
GATE CSE 2010 | Question: 19
A relational schema for a train reservation database is given below. passenger(pid, pname, age) reservation(pid, class, tid) ... (SELECT * FROM Passenger WHERE age>65 AND Passenger.pid=Reservation.pid) $1, 0$ $1, 2$ $1, 3$ $1, 5$
A relational schema for a train reservation database is given below.passenger(pid, pname, age)reservation(pid, class, tid)$$\overset{\text{Passenger}}{\begin{array}{|c|c|...
8.4k
views
answered
Sep 30, 2014
Databases
gatecse-2010
databases
sql
normal
+
–
41
votes
18
GATE CSE 2010 | Question: 43
The following functional dependencies hold for relations $R(A, B, C)$ and $S(B, D, E).$ $ B \to A$ $A \to C$ The relation $R$ contains $200$ tuples and the relation $S$ contains $100$ tuples. What is the maximum number of tuples possible in the natural join $R \bowtie S$? $100$ $200$ $300$ $2000$
The following functional dependencies hold for relations $R(A, B, C)$ and $S(B, D, E).$ $ B \to A$$A \to C$The relation $R$ contains $200$ tuples and the relation $S$ con...
13.2k
views
answered
Sep 30, 2014
Databases
gatecse-2010
databases
normal
natural-join
database-normalization
+
–
35
votes
19
GATE CSE 2000 | Question: 2.26
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 of the following pairs is not equivalent? $x = 5 \quad not (not (x = 5))$ $x = 5 \quad x > 4$ and $x < 6,$ where $x$ is an integer $x ≠ 5 \quad not (x = 5)$ none of the above
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 ...
18.9k
views
answered
Sep 25, 2014
Databases
gatecse-2000
databases
sql
normal
+
–
15
votes
20
GATE CSE 2000 | Question: 2.25
Given relations r(w, x) and s(y, z) the result of select distinct w, x from r, s is guaranteed to be same as r, provided. r has no duplicates and s is non-empty r and s have no duplicates s has no duplicates and r is non-empty r and s have the same number of tuples
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...
16.5k
views
answered
Sep 25, 2014
Databases
gatecse-2000
databases
sql
+
–
40
votes
21
GATE CSE 2000 | Question: 2.24
Given the following relation instance. ... $YZ \rightarrow X$ and $Y \rightarrow Z$ $YZ \rightarrow X$ and $X \rightarrow Z$ $XZ \rightarrow Y$ and $Y \rightarrow X$
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...
14.9k
views
answered
Sep 25, 2014
Databases
gatecse-2000
databases
database-normalization
easy
+
–
–5
votes
22
GATE CSE 2000 | Question: 1.23, ISRO2016-57
Given the relations employee (name, salary, dept-no), and department (dept-no, dept-name,address), Which of the following queries cannot be expressed using the basic relational algebra operations ... whose name is the same as their department name The sum of all employees' salaries All employees of a given department
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...
14.9k
views
answered
Sep 25, 2014
Databases
gatecse-2000
databases
relational-algebra
easy
isro2016
+
–
–6
votes
23
GATE CSE 2000 | Question: 1.22, UGCNET-June2012-II: 11
B$^{+}$-trees are preferred to binary trees in databases because Disk capacities are greater than memory capacities Disk access is much slower than memory access Disk data transfer rates are much less than memory data transfer rates Disks are more reliable than memory
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...
15.6k
views
answered
Sep 25, 2014
Databases
gatecse-2000
databases
b-tree
normal
ugcnetcse-june2012-paper2
+
–
15
votes
24
GATE CSE 2008 | Question: 69
Consider the following relational schemes for a library database: Book (Title, Author, Catalog_no, Publisher, Year, Price) Collection(Title, Author, Catalog_no) with the following functional dependencies: $\text{Title Author }\rightarrow\text{ Catalog_no}$ ... $\text{2NF}$ and Collection in $\text{3NF}$ Both Book and Collection are in $\text{2NF}$ only
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...
28.2k
views
answered
Sep 25, 2014
Databases
gatecse-2008
databases
database-normalization
normal
+
–
79
votes
25
GATE CSE 2008 | Question: 68
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. Which of the following queries are equivalent? $\Pi_P \left(R \bowtie S\right)$ ... Only I and II Only I and III Only I, II and III Only I, III and IV
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....
18.1k
views
answered
Sep 25, 2014
Databases
gatecse-2008
databases
relational-algebra
normal
+
–
6
votes
26
GATE CSE 1999 | Question: 2.7, UGCNET-June2014-III: 25
Consider the schema $R=(S,T, U, V)$ and the dependencies $S \rightarrow T, T \rightarrow U, U \rightarrow V$ and $V \rightarrow S$. Let $R = (R1\text{ and } R2)$ be a decomposition such that $R1 \cap R2 \neq \phi$. The decomposition ... but not $\textsf{3NF}$ in $\textsf{3NF}$ but not in $\textsf{2NF}$ in both $\textsf{2NF}$ and $\textsf{3NF}$
Consider the schema $R=(S,T, U, V)$ and the dependencies $S \rightarrow T, T \rightarrow U, U \rightarrow V$ and $V \rightarrow S$. Let $R = (R1\text{ and } R2)$ be a dec...
27.5k
views
answered
Sep 25, 2014
Databases
gate1999
databases
database-normalization
normal
ugcnetjune2014iii
+
–
55
votes
27
GATE CSE 1999 | Question: 2.25
Which of the following is/are correct? An SQL query automatically eliminates duplicates An SQL query will not work if there are no indexes on the relations SQL permits attribute names to be repeated in the same relation None of the above
Which of the following is/are correct?An SQL query automatically eliminates duplicatesAn SQL query will not work if there are no indexes on the relationsSQL permits attri...
20.0k
views
answered
Sep 25, 2014
Databases
gate1999
databases
sql
easy
+
–
32
votes
28
GATE CSE 1999 | Question: 22-a
Consider the set of relations EMP (Employee-no. Dept-no, Employee-name, Salary) DEPT (Dept-no. Dept-name, Location) Write an SQL query to: Find all employees names who work in departments located at ‘Calcutta’ and whose salary is greater than Rs.50,000. Calculate, for each department number, the number of employees with a salary greater than Rs. 1,00,000.
Consider the set of relationsEMP (Employee-no. Dept-no, Employee-name, Salary)DEPT (Dept-no. Dept-name, Location)Write an SQL query to:Find all employees names who work i...
12.4k
views
answered
Sep 25, 2014
Databases
gate1999
databases
sql
easy
descriptive
+
–
2
votes
29
UGC NET CSE | July 2018 | Part 2 | Question: 64
Relations produced from E-R Model will always be in _____ 1 NF 2 NF 3 NF 4 NF
Relations produced from E-R Model will always be in _____1 NF2 NF3 NF4 NF
23.8k
views
answered
Sep 25, 2014
Databases
databases
er-diagram
database-normalization
ugcnetcse-july2018-paper2
+
–
16
votes
30
GATE CSE 2007 | Question: 62, UGCNET-June2014-II: 47
Which one of the following statements is $\text{FALSE}$? Any relation with two attributes is in $\text{BCNF}$ A relation in which every key has only one attribute is in $\text{2NF}$ A prime attribute can be transitively dependent on ... a $\text{3 NF}$ relation A prime attribute can be transitively dependent on a key in a $\text{BCNF}$ relation
Which one of the following statements is $\text{FALSE}$?Any relation with two attributes is in $\text{BCNF}$A relation in which every key has only one attribute is in $\t...
24.4k
views
answered
Sep 24, 2014
Databases
gatecse-2007
databases
database-normalization
normal
ugcnetcse-june2014-paper2
+
–
Page:
1
2
next »
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register