Installed Java 14 but Java -version still showing old Java

人走茶凉 提交于 2020-12-15 05:06:22

问题


I have installed java 14 in my system at following location.C:\Program Files\Java\jdk-14.0.1 but on running java -version it is still pointing to java version "1.8.0_251". How do I change that to point to Java 14.

I have set my JAVA_HOME to C:\Program Files\Java\jdk-14.0.1\bin and appended the same to Path of system variables but still it is showing the older version.

Why is it happening, a little help will be deeply appreciated. Thanks


回答1:


I found the problem, the Path system variable had entries from previously installed java versions. removing them did the trick. Thanks all for helping out with comments.



来源:https://stackoverflow.com/questions/61722180/installed-java-14-but-java-version-still-showing-old-java

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!