eplise连接mysql2008r2

更新时间:02-11 教程 由 杯与酒 分享

在Eclipse中连接Microsoft SQL Server 2008 R2数据库比较方便,只需要安装适当的驱动程序和插件即可。

首先,在Eclipse的“Help”菜单中找到“Install New Software”选项。

http://download.eclipse.org/releases/indigo/

将此链接添加到“Work with”框中,然后在列表中选择“Database Development”类别并安装“Data Tools Platform (DTP)”插件。

http://www.microsoft.com/downloads/details.aspx?FamilyID=ceb4346f-657f-4d28-83f5-aae0c5c83d52&displaylang=en

下载并安装Microsoft JDBC驱动程序。在项目中添加JAR文件以便Eclipse可以使用它。然后,在Eclipse“Window”菜单中选择“Preferences”选项。

在“Preferences”窗口中找到“Data Management”选项,然后选择“Connectivity”子选项。单击“Driver Definitions”以添加JDBC驱动程序。在弹出的对话框中单击“New Driver Definition”。

org.eclipse.datatools.connectivity.db.generic.driverClass

将此值填入“Driver Class”框中并单击“OK”。

现在在Eclipse中创建新的数据库连接:

jdbc:sqlserver://servername:1433;databaseName=databasename;selectMethod=cursor

在“User ID”和“Password”框中键入您的数据库登录凭据,并单击“Test Connection”以验证连接是否成功。

现在您可以使用Eclipse访问Microsoft SQL Server 2008 R2数据库。

声明:关于《eplise连接mysql2008r2》以上内容仅供参考,若您的权利被侵害,请联系13825271@qq.com
本文网址:http://www.25820.com/tutorial/14_2074850.html