Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 11-14-2011, 08:31 AM   #1
Registered: Jun 2011
Posts: 96

Rep: Reputation: Disabled
eclipse to mysql

Hi guys, i am trying to connect eclipse to mysql and i googled for the connector and found that is connector jand i downloaded it and read a few tutorials about it but they didn't help , so please help me to install and configure that plugin.
Old 11-15-2011, 01:20 AM   #2
LQ Guru
Registered: Apr 2005
Posts: 5,818

Rep: Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004Reputation: 1004
Wait, huh?? Could you explain this again?
If I think I know what you are talking about, would the following help?


Old 11-15-2011, 03:46 AM   #3
Registered: Apr 2011
Location: UK
Distribution: Kubuntu 11.10
Posts: 562

Rep: Reputation: 102Reputation: 102
This is from memory, and seeing what's on my system, as I'm not using MySQL atm ...

You download the Connector/J archive (tar.gz or zip, tar probably better) file from the MySQL web site.
Unpack it somewhere on your system. I have eclipse in /opt/eclipseNNN/eclipse and I put connector/J into /opt/eclipse351/mysql-connector-java-5.1.12/.
In your eclipse project, add (in project properties - java build path) the external jar which will be something like /opt/eclipse351/mysql-connector-java-5.1.12/mysql-connector-java-5.1.12-bin.jar.
Then in your class you need code like
String url = "jdbc:mysql://localhost:3306/" + dbname;
Connection con = DriverManager.getConnection(url, username, password);
1 members found this post helpful.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Metrics plug-in for Eclipse, does it support Eclipse CDT? like2learn Programming 2 04-02-2012 03:13 AM
MySQL - Foreign key failure - but the problem is with Eclipse, I think... nbcohen Linux - Server 2 05-04-2011 08:00 AM
Problems with eclipse and mysql-connector-java post kernel 2.6.26 in Debian robertkey Debian 10 03-24-2010 01:29 AM
Eclipse mp3 player model type: ECLIPSE-CL2BLK Bagatelle Linux - Newbie 0 12-25-2009 01:39 PM
LXer: Gentleware Unveils New Apollo for Eclipse and openArchitectureWare Eclipse Dist LXer Syndicated Linux News 0 10-25-2007 09:30 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:37 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration