Code: Select all
set tmpstring="String with ^^ character"
Question: how to remove quotes but ^^ should remain there. If I use %~ then one ^ gets removed.
Thanks,
Saso
Moderator: DosItHelp
Code: Select all
set tmpstring="String with ^^ character"
Code: Select all
@echo off &setlocal
set tmpstring="String with ^^ character"
call :proc %tmpstring:^=^^%
pause
goto :eof
:proc
echo %~1
set x=%~1
echo %x%
set "y=%~1"
echo %y%
goto :eof
Code: Select all
set "y=%~1"
Code: Select all
>TEST.csv type nul
for /f "delims=: tokens=2" %%a in ('FINDSTR /C:"AP" channelTransaction*.csv ^| FINDSTR /C:"C2S"') do >>TEST.csv echo %%a
Code: Select all
>TEST.csv type nul
for /f "delims=: tokens=2" %%a in ('FINDSTR "AP C2S" channelTransaction*.csv') do >>TEST.csv echo %%a
Code: Select all
type channelTransaction*.csv>TEST.csv
Code: Select all
for /f "usebackq delims=: tokens=2" %%a in ("test.csv") do (
for /f "delims=," %%b in ("%%a") do >>TEST1.csv echo %%b
)