Hi Goetz,

I also had a quick try myself. It works without any problems on my setup (without the 'compare' function) and gives me the following results:

local:getLabel('_and', 'FR')  -->  et
local:getLabel('_and')          -->  und

Setup:
OS X 10.10
java version "1.8.0_25"
BaseX 8.0.3 GUI

You find the code as attachment ... does this help?

Cheers,
Lukas

On Tue, Mar 24, 2015 at 3:33 PM, Christian Grün <christian.gruen@gmail.com> wrote:
Dear Goetz,

Thanks for your mail.

> The first function appears to work as expected. However, instead of “[@LG =
> $lang]” I had to use [compare(@LG, $lang) = 0]” – I don’t know why, but
> otherwise, it does not return any results.

I tried the query, but I get a result in both cases, no matter if I
use compare() or "=". Did you refer to the first or second of your two
local:getLabel functions? Could you possibly minimize the example even
more?

Thanks in advance,
Christian


>
> On the other hand, using “[@label = $key]” on the same line worked.
>
>
>
> The second function does not return anything at all.
>
>
>
> The debug version of the latter shows that all the needed information is in
> place. Obviously, usage of the same variable name globally and locally is
> not an issue (I’ve tried it out).
>
>
>
> What’s wrong with the code? Is there an issue with the current version
> (8.0.3)? My installation runs on a Windows 8.1 machine.
>
>
>
> Some help is appreciated.
>
>
>
> Kind regards,
>
>
>
> Goetz