Statements in HQL are almost exclusively (and if there are indeed exceptions, I’m sure you can recognise them) based on entity definitions in WebDSL. This means that, using those definitions, type checks can be done for the HQL statements. This would be a great help in developing WebDSL applications. Even name checking, so checking for existence of properties, would be ideal.

Submitted by Thomas Schaap on 1 April 2010 at 19:54

On 25 May 2010 at 15:41 Nathan Bruning commented:

Yes, this would make a nice feature.

Because variables can be introduced inside the query, renaming is also needed. This also allows for reference resolving in the editor.


On 25 May 2010 at 15:55 Sander Vermolen commented:

Additionally, note that HQL type checking which is available, is frequently incorrect. For example, consider a simple data model with projects and users, in which a project has a set of users, called members. The following statement is type incorrect according to the type checker:


var projectMembers : List :=
select m
from Project as p
join p.members as m;

Whereas, the type checker thinks the following statement (User -> Project) is type correct:


var projectMembers : List :=
select m
from Project as p
join p.members as m;

Apparently, the select clause is not recognized by the type checker.

Log in to post comments