|
Answer» Anyone know how to prompt for a value and upshift the INPUT?
I need a table name before calling SQL Plus and it has to be in upper case.
ThanksFound this in the snippet closet. KNEW it would be needed someday. You'll need to tweak this for your needs, but this will convert a string entered at the prompt to UPPERCASE:
Code: [Select]echo off
setlocal enabledelayedexpansion
set /p DB=Enter Database Name:
set u=ABCDEFGHIJKLMNOPQRSTUVWXYZ set L=abcdefghijklmnopqrstuvwxyz
set database=%db% for /l %%b in (0,1,25) do call :u !l:~%%b,1! !u:~%%b,1! echo "%db%" has been converted to "!database!" GOTO :eof
:u set "database=!database:%1=%2!" goto :eof
Good luck.
|