• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

how to install and configure sqlserver jdbc driver type 4

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please i really need help on how to install and configure sql server 2012 jdbc driver i have set my enviromental variables, i even set the classpath in the command prompt like this set CLASSPATH =.;C:\Users\T-BAM\Desktop\sqljdbc_4.0\enu\sqljdbc4.jar i tried to unzip it into my Program Files its giving an error message like could not create C:\Program Files\Microsoft SQL Server JDBC Driver\sqljdbc_4.0 - unzip operation cancelled i eventually created a folder in program files Microsoft SQL Server JDBC Driver and set the classpath like this set CLASSPATH =.; C:\Program Files\Microsoft SQL Server JDBC Driver\sqljdbc_4.0\enu\sqljdbc4.jar still not working or is anything wrong with my simple code which goes like this

Please i really need help on how to install and configure sql server 2012 jdbc driver i have set my enviromental variables, i even set the classpath in the command prompt like this set CLASSPATH =.;C:\Users\T-BAM\Desktop\sqljdbc_4.0\enu\sqljdbc4.jar i tried to unzip it into my Program Files its giving an error message like could not create C:\Program Files\Microsoft SQL Server JDBC Driver\sqljdbc_4.0 - unzip operation cancelled i eventually created a folder in program files Microsoft SQL Server JDBC Driver and set the classpath like this set CLASSPATH =.; C:\Program Files\Microsoft SQL Server JDBC Driver\sqljdbc_4.0\enu\sqljdbc4.jar still not working or is anything wrong with my simple code which goes like this


after clicking the jButton1 it throws an exception : Error occured
Error:java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.SQLServerDriver
I have read various articles to help my self still not working, I will so much appreciate it if anyone can help me solve this problem that is giving me sleepless night

after clicking the jButton1 it throws an exception : Error occured
Error:java.lang.ClassNotFoundException: com.microsoft.sqlserver.jdbc.SQLServerDriver
I have read various articles to help my self still not working, I will so much appreciate it if anyone can help me solve this problem that is giving me sleepless night
 
Bartender
Posts: 3648
16
Mac OS X Firefox Browser Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
From your post, you seem to have the jdbc jar in your classpath ok. How are you compiling your java class? In IDE or at command prompt?

If command prompt, you may want to use the -d flag. If IDE, make sure the jdbc jar is added to your project.

Another thing the connection string is somewhat wrong, should be:

The connection URL is jdbc:sqlserver://host:port;databaseName=db



Hope you change this will work.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!