Vidyalelo
MySQL · Q868

MySQL

Programming · MySQL · question 868

Q868

Which of the following statements is/are correct?

A.
True AND true =true
B.
True AND false= false
C.
False AND false= false
D.
All of the mentioned
Answer

Answer: Option D

Solution

Answer: Option D
Solution:
This question is about how AND operator works in MySQL. The AND operator checks if both conditions on either side of it are true.
Let's look at each option:
Option A: True AND true =true
This is correct because both conditions are true, so the entire statement is true.
Option B: True AND false= false
This is also correct. Even though one condition is true, the other is false. Because AND requires both conditions to be true, the whole statement becomes false.
Option C: False AND false= false
This is correct. Both conditions are false, so the entire statement is false.
Option D: All of the mentioned
Since options A, B, and C are all correct, Option D is the correct answer.
In short, the AND operator in MySQL works like this: if both sides are true, the result is true. If even one side is false, the result is false.