title: Batch: how to check variables in the same batch with spaces in them
body: <p>I would like to know if its possible to use spaces in variables in the same batch file and compare it with another variable even though they both have spaces in them.</p>
  
  <p><em><strong>Example:</em></strong>  </p>
  
  <pre><code>@echo off
  CLS
  set var1=variable 1
  set var2=variable 2
  IF %var1%==%var2% (
  goto matches
  ) else (
  goto doesnt
  )
  :matches
  echo.
  echo  Both the Variables Match!
  echo.
  pause
  exit
  :doesnt
  echo.
  echo  Both the Variables DO NOT Match!
  echo.
  pause
  exit
  </code></pre>
  
  <p>just adding that code as an example since a simple way of learning it i could use it as a reference to help me remember.</p>
  
  <p>Showing me how to make the example above to work, would help me greatly if its possible to match variables while still containing its spaces. I know a good bit about Batch, just don't exactly know how to get spaces to work in variables in that way. Thanks for your time, hopefully there's a Solution.</p>