2
votes

I recently updated to jmeter 4.0 from jmeter 3.2. In jmx file, i have query to execute and it was running fine in jmeter 3.2 . But the jmx file fails with error "Response message: java.sql.SQLException: Cannot load JDBC driver class 'com.microsoft.sqlserver.jdbc.SQLServerDriver'" in jmeter 4.0. Please help me in resolving this issue.

below is the screenshot of JDBC Connection ConfigurationJDBC connection config

1
did you have in Test Plan library added manually? did you added JDBC jar to JMeter 4 lib folder?user7294900
I had added "sqljdbc41.jar" in apache-jmeter-4.0\lib path. Do i need to add any extra jars?Praveen PS
what's your java version?user7294900

1 Answers

4
votes

You need to

  1. Download Microsoft JDBC Driver for SQL Server
  2. Extract mssql-jdbc-x.x.x.jrex.jar somewhere to JMeter Classpath
  3. Restart JMeter to pick the .jar up

See Building a Database Test Plan and How to use Different JDBC Drivers articles for more details on how to use JMeter for database testing.