Variable

Set variable To declare a variable, use the following syntax:

SET variablename="value"


Call variable To call the variable, use the following syntax:

SET variablename="Hello"
ECHO %variablename%


Clean variables Always clean up the variable after it is being used.

SET variablename="Hello, world"
ECHO %variablename%
SET variablename=&::
ECHO %variablename%

Reference: http://www.thetechguide.com/howto/2kdos/04-05.html