[daisy] May have found a bug in Navigation, want to make sure..
Marc Portier
mpo at outerthought.org
Thu Apr 5 01:31:42 CDT 2007
Alan Mortensen wrote:
> I'm using the nested queries feature of the navigation document and I'm
> having trouble with referencing the containing row.
>
> In particular, whenever I try to use a ${xxx} kind of reference in a
> query it fails saying things like the value of '
> org.outerj.daisy.navigation.impl.ContextValue at f0c39' cannot be converted
> to a long. I've tried this both with ${documentId} and ${2} (for the
> second field of the current row) and both come back as the ContextValue
> object stringified. It looks to me like the string value is not being
> determined correctly for ContextValue objects, but I want to make sure
> my assumptions are correct.
>
hm,
admittedly, this does sound like some context still assuming document-id
is a long rather then a string (so you are working on 2.0, right? The
final released version?)
> Ex:
> select name where documentType='parent'
> select name where documentType='child' and
> $parentLink.documentId=${documentId}
> OR
> select name, $ParentId where documentType='parent'
> select name where documentType='child' and ${2}=$parentLink=>$ParentId
>
one more attempt I'ld do is this version:
select name, link where documentType='parent'
select name where documentType='child' and ${2}=$parentLink
(warning: untested & from memory, but should work)
'link' is different then document-id, cause it takes into account the
complete variantkey (including branch and language) which is:
- often better then only documentId since you want to stick to the
current variant most of the time anyway
- not going to make a difference in installations where there only the
default variant(branch/language) is in use
pls report back,
regards,
-marc=
More information about the daisy
mailing list