This is my first batch program and I have been searching online but still struggling to write up a solution.
I have the following CSV file:
\"RH\",2013/0
You need to enable delayed expansion:
@echo off setlocal EnableDelayedExpansion set "_InputFile=..." for /f "tokens=1-18* delims=," %%A in (%_InputFile%) do ( Set _var1=%%A Set _var2=%%B ... if "!_var1!"=="RH" echo !_var2! )