0

i want to know if i can run multiple JDK's on my PC and use them all

if i can, what is the value of the PATH on system variable

thanks for help

Sunil Kumar
  • 7,086
  • 4
  • 32
  • 50
HAA
  • 1
  • 1
  • many duplicates; here's one: http://stackoverflow.com/questions/886744/how-install-multiple-jdk-on-windows and another: http://stackoverflow.com/questions/271609/multiple-java-versions-running-concurrently-under-windows ... ain't Google wonderful? – Anon Apr 29 '11 at 20:58

1 Answers1

3

Yes, you can install as many JDKs as you like. Just put them in different folders.

The one you refer to on the path is your choice - but presumably you'd choose the one that you want to use whenever you type "java ...." commands at the command line. In the absence of any other factors you should probably set this to be your most recent JDK version.

Note that your IDE may support multiple JDKs, for example Eclipse has "Preferences / Java / Installed JREs" where you can set up multiple JDKs/JREs for use with Eclipse.

mikera
  • 105,238
  • 25
  • 256
  • 415
  • You can also right click on a jar and choose which jdk to run it with... I commonly have both java 6 and 7 intalled, and test apps versus both. – vikingsteve Jan 13 '14 at 12:11