本文介绍了执行JPQL查询的工具?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有任何类型的工具可以直接对数据库执行JPQL查询?我想直接在窗口中键入JPQL查询并执行它们。

Is there any sort of tool available which allows one to execute JPQL queries against a database "directly"? I would like to type JPQL queries directly into a window and execute them.

当然,它可能需要我做一些配置,以便它能够意识到我的JPA实体等等,但我想可以做到......有人知道这样的工具吗?

Of course it would probably require me to do quite a bit of configuration so that it would be aware of my JPA entities, etc., but I guess it could be done... Anyone know of such a tool?

谢谢。

推荐答案

直到Eclipse Dali获得,您可以使用。 Hibernate Tools与Dali一起使用,并提供了一个HQL / JPQL查询编辑器,它使用Hibernate来执行查询。

Until Eclipse Dali gets a generic JPQL editor you can use Hibernate Tools. Hibernate Tools works with Dali and provides a HQL/JPQL query editor which uses Hibernate to execute the queries.

另一种方法是使用 [JQT],一个交互式JPA查询编辑器和运行器。它可能更接近你正在寻找的东西(作为一个独立的应用程序运行)。

An alternative would be to use the JPA Query Tool [JQT], an Interactive JPA query editor and runner. It might be closer to what you're looking for (runs as a standalone application).

更新:我删除了为NetBeans建议的工具,项目处于非活动状态并且没有不提供任何东西。

Update: I removed the tool suggested for NetBeans, the project is inactive and doesn't provide anything.

这篇关于执行JPQL查询的工具?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-16 11:15