I need to write a policy that will help me assign users to GW post
offices. We have 200+ post offices and I would like to avoid writing 200+
rules. I want to assign an attribute to each of my OU containers in my
eDir tree that will serve as a default post office location. For example,
if a user is placed in the Snyder OU, I want that user to be placed in the
HQ GW post office. I want to be able to read that attribute that is
located on the Snyder OU object that has a value of 'HQ'. I found the
query rule below that is similar to what I am trying to do...except it is
searching all the OUs in the destination data source, whereas I am trying
to query the OU in the source tree (where the user object is located).

Can anyone point me in the right direction? And can I write this policy
without including class OU in the filter?

Any help would be much appreciated,

<?xml version="1.0" encoding="UTF-8"?><policy
> >

> > <rule>
> > <description>GetData</description>
> > <conditions>
> > <and>
> > <if-class-name op="equal">User</if-class-name>
> > </and>
> > </conditions>
> > <actions>
> > <do-set-local-variable name="user-locID">
> > <arg-string>
> > <token-op-attr name="workforceID"/>
> > </arg-string>
> > </do-set-local-variable>
> > <do-set-local-variable name="result">
> > <arg-string>
> > <token-xpath expression='query:search($destQueryProcessor, "subtree",
> > "", "", "Organizational Unit", "OU", $user-locID, "L,Telephone
> > Number")/attr[@attr-name="L"]/value'/>
> > </arg-string>
> > </do-set-local-variable>
> > </actions>
> > </rule>
> > </policy>