<html><div style='background-color:'><DIV class=RTE>
<P>Hi Rick,</P>
<P>I would create a view that joins the list of PLANT users with the AGR_USERS table specifying&nbsp;the the role id that gives that particular authorization (AGR_USERS-AGR_NAME).</P>
<P>Once you get such a list, what will you do with it?&nbsp; You say you want to send it to all of the people on the list.&nbsp; You could do that with dynamic work item generation, but then all the users get their own work item, not a shared work item.</P>
<P>Another way would be to create a rule using a function module wrapper around the selection logic from the above view and then use the rule for agent determination.&nbsp; That way it is a common/shared work item and the first one who gets it owns it and it is removed from all other inboxes.</P>
<P>Hope this helps.</P>
<P>Ed Diehl</P>
<P><BR><BR></P></DIV>
<DIV></DIV>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #a0c6e5 2px solid; MARGIN-RIGHT: 0px"><FONT style="FONT-SIZE: 11px; FONT-FAMILY: tahoma,sans-serif">
<HR color=#a0c6e5 SIZE=1>

<DIV></DIV>From:&nbsp;&nbsp;<I>"Rick Sample" &lt;Rick.Sample@gbe.com&gt;</I><BR>Reply-To:&nbsp;&nbsp;<I>"SAP Workflow Users' Group" &lt;sap-wug@mit.edu&gt;</I><BR>To:&nbsp;&nbsp;<I>sap-wug@mit.edu</I><BR>Subject:&nbsp;&nbsp;<I>Route by Security question</I><BR>Date:&nbsp;&nbsp;<I>Wed, 05 Jul 2006 10:36:16 -0500</I><BR>&gt;I have a task where the only practical way to find an agent is to send<BR>&gt;to all users in a PLANT with a specific Security Auth.<BR>&gt;<BR>&gt;Any existing FM to get a "List" of users for a specific security auth?<BR>&gt;<BR>&gt;<BR>&gt;I can get a list of users in a PLANT, and then loop through that list<BR>&gt;using AUTHORITY_CHECK to determine but I would think their is an<BR>&gt;existing more elegant approach.<BR>&gt;<BR>&gt;4.6c<BR>&gt;<BR>&gt;TIA,<BR>&gt;Rick Sample<BR>&gt;SAP Workflow Analyst/Developer<BR>&gt;Graybar, 
Inc.<BR>&gt;<BR>&gt;<BR>&gt;_______________________________________________<BR>&gt;SAP-WUG mailing list<BR>&gt;SAP-WUG@mit.edu<BR>&gt;http://mailman.mit.edu/mailman/listinfo/sap-wug<BR></FONT></BLOCKQUOTE></div></html>