When I do where java in the cmd terminal, I get the following results:
C:\Program Files\Java\jdk1.7.0_25\bin\java.exe
C:\Windows\System32\java.exeIs it meant to do that? I thought it should only produce the first result as that's what's set in my Path environmental variable. I am using Windows 8 if that helps.
22 Answers
C:\Program Files\Java\jdk1.7.0_25\bin\java.exe is the entry you get because you defined it in the Path.
You are getting the second one, because you have a java.exe in your System32 folder. I guess the installer did this.
By default your PATH always have C:\Windows\System32, where just looks for the location of the file with search pattern and in your case, you added jdk bin location to your PATH, also your system32 folder also has java.exe, thats why you see two entries in your output.