替代 Apache Commons DbUtils 的轻量级 JDBC 帮助程序库 [英] Lightweight JDBC helper library alternative to Apache Commons DbUtils

查看:25
本文介绍了替代 Apache Commons DbUtils 的轻量级 JDBC 帮助程序库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚开发了自己的小型 JDBC 帮助程序库,并且我已经意识到这将是一个多么可怕的维护噩梦.

I've just developed my own tiny little JDBC helper library, and I've already realized what a maintenance nightmare it will be.

我不是在寻找一个完整的 ORM,比如 Hibernate,只是为了快速使 JDBC 调用传递 SQL 语句而不会弄乱检查的异常、手动关闭资源等...

I'm not looking for a full fledged ORM, like Hibernate, just something light and useful to quickly make JDBC calls passing SQL statements without messing with checked exceptions, closing resources manually, etc...

根据您的经验,您能推荐一个不错的 JDBC 帮助程序库吗?

From your experiencie, can you recommend a nice JDBC helper library?

到目前为止,我已经看过 Apache Commons DbUtils非常好.还有其他想法吗?

So far now, I've had a look at Apache Commons DbUtils which seems pretty good. Any other idea?

推荐答案

这是缓解痛苦"的工具列表与简单的 JDBC 交互时:

Here's a list of tools that "ease the pain" when interacting with simple JDBC:

  • Spring's JdbcTemplate
  • jOOQ (can be used with SQL strings as well - disclaimer: I work for the vendor)
  • Apache DbUtils (which you've mentioned yourself)
  • JDBI
  • sql2o
  • persism

这篇关于替代 Apache Commons DbUtils 的轻量级 JDBC 帮助程序库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆