Windows batch files: multiple if conditions

The “and” turns out to be easy — just not the syntax you expect:
These 3 examples illustrate it.

In words: If 1==1 AND 2==2 Then echo “hello”

if 1==1 echo hello
hello

if 1==1 if 2==2 echo hello
hello

if 1==1 if 2==1 echo hello
(nothing was echoed)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)