hi all,
i’ll show you my problem!
it’s possible to replace something like this:
for $a in doc( '/db/tesi/UtentiIstanza.xml' )/utenti/utente
where $a/credenziali/unacredenziale[nomecredenziale='CI']/residenza='Milano'
return $a/id
with something like this:
let $expcred := "credenziali/unacredenziale[nomecredenziale='CI']/residenza='Milano'"
for $a in doc( '/db/tesi/UtentiIstanza.xml' )/utenti/utente
where $a/$expcred
return $a/id
the first example works,the second no,how can i do?
i’ve tryied many other solutions but it never works
I need to use this in a function and $expcred is one of my parameters
thanks a lot for your help
Matthew
this is my XML
0 admin admin 1 teyo qwerty CI O'Brien Matthew Milano studente BIB O'Brien Matthew MI12345