Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

MySql Question

 
Joe Richard
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Does anyone know how to connect to a MySql database on a PC with eclipse as the IDE?
Any help would be greatly appreciated.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You need to be a little more specific in your question. Are you having problems connecting with your code you wrote using Eclipse? Or are you wanting something like a Mysql Front inside of eclipse. If this is the case there are plenty of plugins available and you can find them here.
Unless this has more to do with JDBC I will be moving it to the IDE forum. Waiting on you....
 
Joe Richard
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am having a problem with the Driver in eclipse. I have added the correct library to my project. But I still am having problems importing the com.mysql.jdbc package. Does anyone know how to correct this problem. My other JDBC Drivers (DB2, DB2 iSeries, SQLServer) work fine I cannot get this one to work.
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Chrome IntelliJ IDE Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Joe Richard:
I am having a problem with the Driver in eclipse. I have added the correct library to my project. But I still am having problems importing the com.mysql.jdbc package. Does anyone know how to correct this problem. My other JDBC Drivers (DB2, DB2 iSeries, SQLServer) work fine I cannot get this one to work.

Importing the package? There is no reason you should be importing the package in your java code as in
import com.mysql.jdbc.*
or any varient there of. This is done dynamically when you do Class.forName("com.mysql.jdbc.Driver"); Unless I am missing something.
Are you getting errors? Can we see some code? Is this an Eclipse question?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic