AND

  • Thread starter Thread starter Guest
  • Start date Start date
I cud bt I cnt rd ur txt

--

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
It is effectively doing two tests at the same time

AND(cond1=val1,cond2=val2)

and usually is combined with IF to test the two at once

=IF(AND(cond1=val1,cond2=val2),...

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)
 
sorry.
I want to know the difference between "AND" & "IF"?
Also, where and on what logic is the function "AND" based on?

Thanks for your help.
 
Sorry,

Just wanted to know about the function "AND"? How is it different from "IF".
I am unable to understand the logic of "AND".

Thanks for your help.
 
If Bob's explanation is not enough then try writing IF and AND in a
sentence:

If you ask a question THEN you will get an answer OTHERWISE you will not:

IF <this condition is TRUE> THEN you will get this answer OTHERWISE you will
get another answer:

Replace THEN and OTHERWISE with commas to give:

IF(do a TEST, Answer1 if TEST is TRUE, Answer2 if TEST is not TRUE)



IF you ask a question AND I can understand what you are saying THEN I will
answer OTHERWISE I will not

IF(AND(Do TEST 1, Do TEST 2), Do only if BOTH TEST 1 & TEST 2 are TRUE, Do
if only one or none of the tests are TRUE)

So there is no actual comparison possible between IF and AND because they do
different things. IF is a 'Y' branch: do this or that depending on the
result of a test. AND combines two, (or more) tests together to give one
TRUE or FALSE answer to the total number of tests.

There is more of a comparison between AND and OR. OR also looks at a
collection of tests but unlike AND which will only return TRUE is ALL tests
are TRUE, OR will return TRUE if only one test is TRUE.

IF(OR(TEST 1, TEST 2, TEST 3), answer if even only one TEST is TRUE, answer
only if all TESTS are FALSE)
--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
Back
Top