If you set a JAVA_HOME parameter, then you can set all your other stuff like classpaths etc in reference to the JAVA_HOME parameter: set path=%JAVA_HOME%\bin;%path% set classpath= .;%JAVA_HOME%\lib; Now you can just switch around your JAVA_HOME parameter and all the related parameters get automatically updated.
The down side of the JAVA_HOME parameter, is that you can forget that you have it set, say in your autoexec.bat, and then you go and tinker around with your classpath, and pick up stuff from the JAVA_HOME directories, causing suprising results - so beware.
"JavaRanch, where the deer and the Certified play" - David O'Meara
yes you r right JAVA_HOME for Tomcat web server. It is using to tell web server in which directory our jdk file reside. No need to mention if u r not using web server.
No Path of Flowers lead to glory
Don't get me started about those stupid light bulbs.