> -----Original Message-----
> From: [EMAIL PROTECTED] 
> [mailto:[EMAIL PROTECTED] On Behalf Of Simon Groenewolt
> 
> I noticed that using a field 'no' on hsqldb was translated to 
> 'm_no' in 
> the database.
> 
> However, if I want to specify a constraint on a listnodes I 
> cannot use 
> 'no' but have to use 'm_no' to get it to work. This is using 
> 1.7 but I 
> remember this was also the case in 1.6.5.
> 
> This could be fixed by also translating the constraint fields 
> couldn't it?

You are right, this is a bug, at least in 1.7.

Before 1.7, the brackets (like in "[status]") provided a workaround.
However, starting with 1.7 queries are parsed into
object-representations (SearchQuery), from which the databaselayer
generates a database-specific SQL statement. As a result, the rewriting
of fieldnames happens entirely transparently to the bridge/taglib code.
The brackets syntax is still supported for backward compatibility, but
not necessary anymore.

The behaviour you describe indicates either one of these two
possibilities:
- the constraint is not fully parsed into a object representation
(Constraint), possibly by using a LegacyConstraint
- the constraint is correctly represented, but the SQL is not generated
correctly from it

In either case it's clearly a bug.

Simon, please report the bug in the bugtracker. I try to review/address
all query-related issues reported here on a regular basis.

Rob van Maris
Technical Consultant

Quantiq
xmedia & communication solutions

Koninginneweg 11-13
1217 KP Hilversum
 
T    +31 (0)356257211
M    +31 (0)651444006
E    [EMAIL PROTECTED]


Reply via email to