564 views
0 votes
0 votes
In sql relations can contain null values,and comparisons with null values are unknown. suppose all comparisons with a null value are treated as false. which of the following pairs is not equivalent ?                                      a.x=5,not (not  (x=5))                                        b.x=5,x>4 and x <6,where x is an integer       c.x <5,not  (x=5)                                                   d.NOT

1 Answer

1 votes
1 votes
Answer: C

As if x is considered NULL, and any comparison with NULL yields False.

Then, x <5 gives FALSE

not (x=5) --> not (False) --> True.

So They are not equivalent.

Related questions

2.5k
views
1 answers
6 votes
Kathleen asked Sep 14, 2014
2,544 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...
3.9k
views
2 answers
12 votes
Kathleen asked Sep 14, 2014
3,901 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, ...
18.7k
views
4 answers
63 votes
Kathleen asked Sep 14, 2014
18,665 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 ...
16.3k
views
4 answers
57 votes
Kathleen asked Sep 14, 2014
16,322 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...
Total PHP MySQL Other RAM
Time (ms) % Time (ms) % File count Time (ms) % Query count Time (ms) % Amount %
Setup 4.3 5% 2.8 3% 72 1.5 1% 2 0.0 0% 569k 53%
Control 14.1 18% 1.5 1% 5 12.8 16% 12 0.0 0% 175k 16%
View 2.2 2% 2.2 2% 11 0.0 0% 0 0.0 0% 74k 6%
Theme 46.1 59% 4.8 6% 15 41.5 53% 3 0.0 0% 248k 23%
Stats 10.3 13% 0.1 0% 0 10.3 13% 1 0.0 0% 0k 0%
Total 77.1 100% 11.4 14% 103 66.1 85% 18 0.0 0% 1068k 100%