hsqldb是否提供类似于Oracle CURSOR的功能?

时间:2021-03-08 19:17:20

In running my junit tests, I'm being given the error:

在运行我的junit测试时,我遇到了错误:

user lacks privilege or object not found: CURSOR

用户缺少未找到的权限或对象:CURSOR

The query is trying to load up a large number of records, with a subquery returning a corresponding one-to-many set of ids.

查询正在尝试加载大量记录,子查询返回相应的一对多id。

Code:

SELECT br.rateid, br.precedence, CURSOR (SELECT rt.trailerid FROM ratetrailer rt WHERE rt.rateid = br.rateid) AS trailer_ids FROM rate br WHERE br.statusID = ?

This works just fine as part of the java code, returning a ResultSet within the main ResultSet.

这作为java代码的一部分工作正常,在主ResultSet中返回ResultSet。

I have oracle compatibility turned on (jdbc:hsqldb:mem:testDB;sql.syntax_ora=true), but have a feeling this is an oracle shortcut/function/whatever rather than a simple syntax tweak. Is it?

我打开了oracle兼容性(jdbc:hsqldb:mem:testDB; sql.syntax_ora = true),但感觉这是一个oracle快捷方式/函数/无论是简单的语法调整。是吗?

1 个解决方案

#1


0  

Returning a ResultSet in a column of another ResultSet is an Oracle feature that is not supported by HSQLDB and most other databases.

在另一个ResultSet的列中返回ResultSet是HSQLDB和大多数其他数据库不支持的Oracle功能。

#1


0  

Returning a ResultSet in a column of another ResultSet is an Oracle feature that is not supported by HSQLDB and most other databases.

在另一个ResultSet的列中返回ResultSet是HSQLDB和大多数其他数据库不支持的Oracle功能。