Here is a good tutorial on setting the class path . Next, you can read Java Class Pool Management (Windows) .
Having said that, you should not set the class path for your driver in a Windows environment variable. Instead, you should enable this jar driver inside your IDE in the project properties. But I noticed that you are actually using Maven. In this case, you should look for a driver under Maven to fulfill this dependency. Maven will load the driver pitcher if it does not exist and make it local.
In case you are not using any IDE, then you can create a lib directory and tell the compiler that all the necessary jar are there at compile time / run time. You can find HOW in the previous link above.
source share