<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=iso-8859-1">
 
 
<META content="MSHTML 5.00.2920.0" name=GENERATOR></HEAD>
<BODY>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=217240606-17012001>Hi
Brad/Rakesh,</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=217240606-17012001>One
option would be to use function module RH_GET_STRUCTURE and the evaluation path
that's used</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=217240606-17012001>to
determine the next-level-up org structure.&nbsp; If you don't find a
next-level-up, you've hit the top.</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=217240606-17012001>A bit
neater than working out the table calls yourself - especially if you don't do a
lot of HR coding.</SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=217240606-17012001></SPAN></FONT>&nbsp;</DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=217240606-17012001>Try
talking to an HR programmer as they may have other helpful function modules to
suggest. </SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN
class=217240606-17012001>Regards, </SPAN></FONT></DIV>
<DIV><FONT color=#0000ff face=Arial size=2><SPAN class=217240606-17012001>
<DIV style="HEIGHT: 90px; WIDTH: 374px"><FONT face=Arial size=2>
<TABLE>
  <TBODY>
  <TR>
    <TD></TD></FONT>
    <TD>
      <DIV><FONT face="Book Antiqua"><FONT size=2><FONT color=#0000ff>Jocelyn
      Dart</FONT> <BR></FONT><FONT color=#0000ff face=Roman size=2>Consultant
      (BBP, Ecommerce, Internet Transaction Server, Workflow)</FONT><FONT
      size=2> <BR><FONT color=#0000ff>SAP Australia</FONT></FONT></FONT></DIV>
      <DIV><FONT face="Book Antiqua"><FONT size=2><FONT color=#0000ff>Email <A
      href="mailto:jocelyn.dart@sap.com">jocelyn.dart@sap.com</A><BR>Tel:
      +61<SPAN class=153385400-09052000> 412 390 267</SPAN><BR>Fax: +61&nbsp;2
      9935
4880</FONT></FONT></FONT></DIV></TD></TR></TBODY></TABLE></DIV></SPAN></FONT></DIV>
<BLOCKQUOTE style="MARGIN-RIGHT: 0px">
  <DIV align=left class=OutlookMessageHeader dir=ltr><FONT face=Tahoma
  size=2>-----Original Message-----<BR><B>From:</B> Rakesh Dube
  [mailto:rakesh_dube@pacific.net.sg]<BR><B>Sent:</B> Wednesday, 17 January 2001
  1:11 PM<BR><B>To:</B> SAP-WUG@MITVMA.MIT.EDU<BR><B>Subject:</B> Re: Trying to
  find top-level org unit<BR><BR></DIV></FONT>Hi Brad, <BR>U have to write&nbsp;
  recursive function module to find out the top-level org unit.
  <P>Tables&nbsp; which is using the relationship is HRP1000 and HRP1001
  <P>HRP1000 is for creating the structure and HRP1001 is for relationship to
  the object
  <P>If u need any further detail let me know <BR>Thanks <BR>Rakesh <BR>&nbsp;
  <BR>&nbsp;
  <P>"Schroeter, Brad" wrote:
  <BLOCKQUOTE TYPE="CITE">&nbsp;
    <P><FONT face=Arial><FONT size=-1>I've got an org structure like
    this:</FONT></FONT> <BR><FONT face=Arial><FONT size=-1>Org unit 50000000
    (top-level)</FONT></FONT> <BR><FONT face=Arial><FONT size=-1>|__Org unit
    50000001</FONT></FONT> <BR><FONT face=Arial><FONT size=-1>|__Org unit
    50000002</FONT></FONT> <BR><FONT face=Arial><FONT size=-1>|__Org unit
    50000003</FONT></FONT>
    <P><FONT face=Arial><FONT size=-1>Let's say I'm currently using org unit
    50000000, I'm in a custom method and I want to find if it's the
    top-level?&nbsp; Is there a database select statement to one of the HRP*
    tables or a function module that will give me the info?</FONT></FONT>
    <P><FONT face=Arial><FONT size=-1>Thanks,</FONT></FONT> <BR><FONT
    face=Arial><FONT
size=-1>Brad</FONT></FONT></P></BLOCKQUOTE></BLOCKQUOTE></BODY></HTML>