search
Log In
0 votes
138 views

What is the correct interpretion of this query

in Databases 138 views
0
Is ESSN(and not SSN) not the second attribute in Employee Relation Schema?
0
Anyway, Result will contain the name of employees who are managers but no one is dependent on them. (Employess with SSN, who are having entry in MGRSSN of department but Not having in ESSN of Dependent)
0
m not getting the C<-----------A-B part pls explainby taking example
0
Well think of it as:

Let say, A has IDs of All the employees who are managers, while B has IDs of all the employees who has someone dependent upon them. Then C = A-B, will simply contain all the managers upon whom no one is dependent.

1 Answer

0 votes

A, B and C are temprary variables

All the MGRSSN will be stored in A from Department table under the column name SSN.
All the ESSN will be stored in B from Dependent table under the column name SSN. So that the set difference can be calculated further.

C <-- A-B 

C will store those MGRSSN who don't have any dependent.

There is natural join of employee with C, it means the names of those employees who are manager and don't have any dependent will be stored in the Result variable.


edited

Related questions

1 vote
1 answer
1
2 votes
4 answers
2
979 views
In a relation, if every attribute is prime but key may not be simple then the relation is in ______. A. 1NF B. 2NF C. 3NF D. BCNF
asked May 27, 2019 in Databases Tuhin Dutta 979 views
1 vote
2 answers
3
486 views
Consider the relation $R\left ( A,B,C,D,E \right )$ with functional dependencies $F=${ $A\rightarrow B$ $BC\rightarrow E$ $ED\rightarrow A$ } Number of additional relation required to convert it into lossless , dependency preserving $3NF$ decomposition is _____________ What is meaning of additional relation (Here no table mentioned previously)??
asked May 19, 2019 in Databases srestha 486 views
2 votes
1 answer
4
557 views
The minimum number of nodes (both leaf and non-leaf) of $B^{+}$ tree index required for storing $5500$ keys and order of $B^{+}$ tree is $8$________________(order is max pointers a node can have) See here first level should be divide by $7$ $2nd$ levelshould divide by ... each $7$ pointer of 1st level has $8$ pointer in 2nd level. Am I missing something?? But in ans they divided by only $8$ :(
asked May 17, 2019 in Databases srestha 557 views
...