Say for example in Control Panel\System and Security\System > Advanced System Settings > System Properties > Advanced Tab > Environment variables...
I have the following PATH:
Value 1:
PATH=%JAVA_HOME%\bin;e:\Groovy\GROOVY~1.0\bin;E:\Python;C:\Users\MyName\AppData\Local\GitHubDesktop\bin;%PYTHON3_HOME%;%GROOVY_HOME%\bin;
when in cmd, I do:
echo %PATH%
then I get:
Value 2:
E:\Program Files\Java\jdk1.8.0_151\bin;e:\Groovy\GROOVY~1.0\bin;C:\Users\MyName\AppData\Local\GitHubDesktop\bin;E:\Program Files\Python\Python36-32;E:\Program Files (x86)\Groovy\Groovy-2.6.0\bin;
Then what command in cmd will be able to print out same exact PATH values with variable names (%JAVA_HOME% etc.) as from the System Properties (Value 1)?