I am building an app which connect to mysql database using intelij idea. I have imported jdbc driver through modules > dependencies and it works great when I run the app through IDE. But when I build an artifact using build > build artifacts > rebuild (tried clean and build also) and I ran it using cmd I get the following error:
java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
I have also tried cleaning and rebuilding project but it didnt help.
Any ideas what am I doing wrong?
Aucun commentaire:
Enregistrer un commentaire