GTR

GTR is a 'Greater Than' comparison operator for the IF command

Examples

C:\> IF 100 GTR 50 ECHO its more than 50!
its more than 50!

C:\> If 130 GTR 14 Echo OK
OK

C:\> If "130" GTR "14" Echo OK

GTR will perform a numeric comparison where possible, if you need a string comparison use the == comparison operator.

In addition to integer numbers, hex and octal numbers can also be compared within certain limits.

“People who know little are usually great talkers, while men who know much say little” ~ Jean Jacques Rousseau

Related:

IF command - EQU, NEQ, LSS, LEQ, GEQ


 
Copyright © SS64.com 1999-2019
Some rights reserved