if this exception come for SQL

java.lang.IncompatibleClassChangeError: Found class com.mysql.jdbc.Statement, but interface was expected

Are you able to please explain ? will it come because of mysql jar changes to next version ?

In mysql-connecter-java-5. Statement is really a class. in five.1, this is an interface.

The code you are writing should not care an excessive amount of. But when you compile from the latest version, then run from the old version, you will have this issue.