简体   繁体   English

什么数据库可以用于java?

[英]what databases can be used with java?

I am doing an undergrad final project, and need to justify my choice of MySQL for the database element of my project. 我正在做一个本科的最终项目,需要证明我选择MySQL作为我项目的数据库元素。 Truth is, it's the only one I can really use, and hence I went for it. 事实是,这是我唯一可以真正使用的,因此我就去了。

What other database systems could I have used? 我可以使用哪些其他数据库系统? Any advantages and disadvantages of these over MySQL? MySQL的这些优点和缺点是什么?

In fact, you can use every database which is accessible through a JDBC driver . 实际上,您可以使用可通过JDBC驱动程序访问的每个数据库。 Almost all self-respected RDBMS vendors provides a fullworthy JDBC driver for download at their homepage. 几乎所有备受推崇的RDBMS供应商都在其主页上提供了一个完整的JDBC驱动程序供下载。 Just Google "[vendorname] jdbc driver download" to find it. 只需Google“[vendorname] jdbc驱动程序下载”即可找到它。 Here's an overview: 这是一个概述:

This way you can use the JDBC API transparently to access either of the databases. 这样,您可以透明地使用JDBC API来访问任一数据库。

As to which database to choose, just look at the features, robustness, performance, etc the RDBMS provides and the budget you have -if it isn't freeware. 至于选择哪个数据库,只需查看RDBMS提供的功能,健壮性,性能等以及您拥有的预算 - 如果它不是免费软件。 I myself tend to prefer PostgreSQL. 我自己更喜欢PostgreSQL。

Instead of a fullfledged database server, you can also consider an embedded Javabased database, such as Sun Oracle JavaDB , Apache Derby , HSQLDB or SQLite , each which are of course accessible through the JDBC API the usual way. 您也可以考虑使用嵌入式 Javabased数据库,例如 Sun Oracle JavaDBApache DerbyHSQLDBSQLite ,而不是完整的数据库服务器,每个数据库都可以通过JDBC API以常规方式访问。

You can use any relational database that has a JDBC driver. 您可以使用具有JDBC驱动程序的任何关系数据库。 These would include PostgreSQL, Hypersonic SQL, MySQL, SQLLite on the free side and Oracle, MS SQL Server, and others on the paid side. 这些将包括免费的PostgreSQL,Hypersonic SQL,MySQL,SQLLite以及付费方面的Oracle,MS SQL Server和其他方面。

The biggest advantage accrued to MySQL in your case is that it's free and you know it. 在你的情况下,MySQL的最大优势是它是免费的,你知道它。 That's enough to make it suitable for what you want to accomplish. 这足以使它适合你想要完成的任务。

You could have used pretty much ANY database. 您可以使用几乎任何数据库。 MSSQL, SQLite, Postgre, Oracle or [put your choice here] MSSQL,SQLite,Postgre,Oracle或[在此处选择]

There's a driver for pretty much any database to integrate with Java. 几乎任何数据库都可以与Java集成。 This is a great place to find out all the DB's java support, as well as how to integrate 是查找所有DB的java支持以及如何集成的好地方

Hope this helps 希望这可以帮助

Have a look at the list of vendors who have endorsed the JDBC API maintained by Sun. 查看已经认可 Sun维护的JDBC API的供应商列表 Also see the list of third-party JDBC technology-enabled drivers which are currently shipping. 另请参阅当前发运的第三方支持JDBC技术的驱动程序列表。

You mentioned MySQL and database. 你提到了MySQL和数据库。 For the case you are free to usa a non RDBMS you can check db4o . 对于您可以自由发布非RDBMS的情况,您可以检查db4o

Advantage: pure OO/Java persistence. 优点:纯OO / Java持久性。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM