I've got an XPATH query in the sub-ET of a Loopback driver that is checking
for the existence of a group and if it exists, does a modify to add members
and if it doesn't it creates the group and adds members. These groups are
created/modified by user events to the directReports attribute. I can see
the query is working and does find the group if it exists, however it
doesn't store any value in the variable and therefore the XPATH evaluation
in the next rule always evaluates incorrectly. Below is a copy of L3 trace.
Any help is appreciated!!


[06/17/08 06:28:10.422]:Loopback - ST:Applying policy: %+C%14CCreate Direct
Reports Groups%-C.
[06/17/08 06:28:10.423]:Loopback - ST: Applying to modify #1.
[06/17/08 06:28:10.423]:Loopback - ST: Evaluating selection criteria for
rule 'Initialize Local Variables'.
[06/17/08 06:28:10.424]:Loopback - ST: (if-op-attr 'directReports'
changing) = TRUE.
[06/17/08 06:28:10.424]:Loopback - ST: Rule selected.
[06/17/08 06:28:10.425]:Loopback - ST: Applying rule 'Initialize Local
Variables'.
[06/17/08 06:28:10.425]:Loopback - ST: Action:
do-set-local-variable("lvarManagerGroupDN",scope="policy","vaul t\groups\dist_group."+token-replace-first("\.","",token-src-name())).
[06/17/08 06:28:10.426]:Loopback - ST:
arg-string("vault\groups\dist_group."+token-replace-first("\.","",token-src-name()))
[06/17/08 06:28:10.427]:Loopback - ST:
token-text("vault\groups\dist_group.")
[06/17/08 06:28:10.427]:Loopback - ST:
token-replace-first("\.","",token-src-name())
[06/17/08 06:28:10.428]:Loopback - ST:
token-replace-first("\.","",token-src-name())
[06/17/08 06:28:10.428]:Loopback - ST: token-src-name()
[06/17/08 06:28:10.429]:Loopback - ST: Token Value:
"adrusch".
[06/17/08 06:28:10.429]:Loopback - ST: Arg Value: "adrusch".
[06/17/08 06:28:10.430]:Loopback - ST: Token Value: "adrusch".
[06/17/08 06:28:10.430]:Loopback - ST: Arg Value:
"vault\groups\dist_group.adrusch".
[06/17/08 06:28:10.431]:Loopback - ST: Action:
do-set-local-variable("lvarSrcDN",scope="policy","vault\groups" ).
[06/17/08 06:28:10.431]:Loopback - ST: arg-string("vault\groups")
[06/17/08 06:28:10.432]:Loopback - ST: token-text("vault\groups")
[06/17/08 06:28:10.432]:Loopback - ST: Arg Value: "vault\groups".
[06/17/08 06:28:10.433]:Loopback - ST: Action:
do-set-local-variable("lvarSearchValue",scope="policy","dist_gr oup."+token-replace-first("\.","",token-src-name())).
[06/17/08 06:28:10.434]:Loopback - ST:
arg-string("dist_group."+token-replace-first("\.","",token-src-name()))
[06/17/08 06:28:10.434]:Loopback - ST: token-text("dist_group.")
[06/17/08 06:28:10.435]:Loopback - ST:
token-replace-first("\.","",token-src-name())
[06/17/08 06:28:10.435]:Loopback - ST:
token-replace-first("\.","",token-src-name())
[06/17/08 06:28:10.436]:Loopback - ST: token-src-name()
[06/17/08 06:28:10.436]:Loopback - ST: Token Value:
"adrusch".
[06/17/08 06:28:10.436]:Loopback - ST: Arg Value: "adrusch".
[06/17/08 06:28:10.437]:Loopback - ST: Token Value: "adrusch".
[06/17/08 06:28:10.437]:Loopback - ST: Arg Value:
"dist_group.adrusch".
[06/17/08 06:28:10.438]:Loopback - ST: Action:
do-set-local-variable("lvarQueryResult",scope="policy",token-xpath("query:search($srcQueryProcessor,'subtree',' ',$lvarSrcDN,'','CN',$lvarSearchValue,'')")).
[06/17/08 06:28:10.439]:Loopback - ST:
arg-string(token-xpath("query:search($srcQueryProcessor,'subtree',' ',$lvarSrcDN,'','CN',$lvarSearchValue,'')"))
[06/17/08 06:28:10.440]:Loopback - ST:
token-xpath("query:search($srcQueryProcessor,'subtree',' ',$lvarSrcDN,'','CN',$lvarSearchValue,'')")
[06/17/08 06:28:10.440]:Loopback - ST: Query from policy
[06/17/08 06:28:10.441]:Loopback - ST:
<nds dtdversion="3.5" ndsversion="8.x">
<source>
<product version="3.5.10.20070918 ">DirXML</product>
<contact>Novell, Inc.</contact>
</source>
<input>
<query dest-dn="vault\groups" scope="subtree">
<search-attr attr-name="CN">
<value>dist_group.adrusch</value>
</search-attr>
<read-attr/>
</query>
</input>
</nds>
[06/17/08 06:28:10.443]:Loopback - ST: Pumping XDS to
eDirectory.
[06/17/08 06:28:10.443]:Loopback - ST: Performing operation
query for vault\groups.
[06/17/08 06:28:10.471]:Loopback - ST: Query from policy result
[06/17/08 06:28:10.471]:Loopback - ST:
<nds dtdversion="3.5" ndsversion="8.x">
<source>
<product version="3.5.10.20070918 ">DirXML</product>
<contact>Novell, Inc.</contact>
</source>
<output>
<instance class-name="Group"
qualified-src-dn="O=vault\OU=groups\CN=dist_group.adrusch"
src-dn="\IDM_VAULT\vault\groups\dist_group.adrusch" src-entry-id="49547"/>
<status level="success"></status>
</output>
</nds>
[06/17/08 06:28:10.474]:Loopback - ST: Token Value: "".
[06/17/08 06:28:10.474]:Loopback - ST: Arg Value: "".
[06/17/08 06:28:10.475]:Loopback - ST: Action:
do-trace-message(level="3","Search Results:
"+token-local-variable("lvarQueryResult")).
[06/17/08 06:28:10.476]:Loopback - ST: arg-string("Search Results:
"+token-local-variable("lvarQueryResult"))
[06/17/08 06:28:10.476]:Loopback - ST: token-text("Search Results:
")
[06/17/08 06:28:10.477]:Loopback - ST:
token-local-variable("lvarQueryResult")
[06/17/08 06:28:10.477]:Loopback - ST: Token Value: "".
[06/17/08 06:28:10.478]:Loopback - ST: Arg Value: "Search Results:
".
[06/17/08 06:28:10.478]:Loopback - ST:Search Results:
[06/17/08 06:28:10.478]:Loopback - ST: Evaluating selection criteria for
rule 'Make changes to Existing Group'.
[06/17/08 06:28:10.479]:Loopback - ST: (if-xpath true
"$lvarQueryResult") = FALSE.
[06/17/08 06:28:10.480]:Loopback - ST: Rule rejected.
[06/17/08 06:28:10.480]:Loopback - ST: Evaluating selection criteria for
rule 'No Group Match Found - Create New Group'.
[06/17/08 06:28:10.481]:Loopback - ST: (if-xpath not-true
"$lvarQueryResult") = TRUE.
[06/17/08 06:28:10.481]:Loopback - ST: Rule selected.
[06/17/08 06:28:10.482]:Loopback - ST: Applying rule 'No Group Match
Found - Create New Group'.