• 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
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

run application with MySql - driver problem

 
Ranch Hand
Posts: 755
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everyone,

I'm using eclipse as my IDE and when compiling and running a program with MySql evreything works perfect.

when I export my project to a jar file and trying to run it from the command line I get error msgs - I take it the MySql driver cannot be found.

I'm doing this:
java -cp mysql-connector-java.jar;GTP.jar com.bonn.main.GTP

can someone tell me what's missing?

thanks
Ppr
[ March 03, 2005: Message edited by: Bear Bibeault ]
 
Bartender
Posts: 10336
Hibernate Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


I get error msgs - I take it the MySql driver cannot be found.


Possibly - a "it works in environment X, but not environment Y" problem is usually the classpath. Read the error message - it should tell you what it can't find. Then check the class is in one of the Jars you have listed in the classpath. If you are still stuck - post the stack trace you see and hopefully someone can point you in the right direction.
 
Peter Primrose
Ranch Hand
Posts: 755
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the message i get is:

com.mysql.jdbc.Driver

Do I need to specify somthing at the Enviroment Veriable???
 
You guys wanna see my fabulous new place? Or do you wanna look at this tiny ad?
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic