Skip to Content
author's profile photo Former Member
Former Member

help to find org.unit manager

hallow

here i try to find org unit manager but its not working well

plz some one can help

i think i have problem in dates but i not sure

thankes & regards

LOOP AT i_t_data INTO lw_t_data_0org.

SELECT begda endda sobid

FROM hrp1001

INTO TABLE lt_relat_org

WHERE objid EQ lw_t_data_0org-orgeh

AND rsign EQ 'B'

AND relat EQ '012'

AND endda GE lw_t_data_0org-datefrom

AND begda LE lw_t_data_0org-dateto.

SORT lt_relat_org BY begda DESCENDING endda DESCENDING sobid.

CLEAR lw_relat_org.

READ TABLE lt_relat_org INDEX 1 INTO lw_relat_org.

IF sy-subrc EQ '0'.

l_plans = lw_relat_org-sobid.

SELECT SINGLE pernr

FROM pa0001

INTO lw_t_data_0org-zzmanager

WHERE endda GE lw_relat_org-begda " lw_t_data_0org-datefrom

AND begda LE lw_relat_org-endda " lw_t_data_0org-dateto

AND plans EQ l_plans.

ENDIF.

APPEND lw_t_data_0org TO lc_t_data_0org.

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Sep 19, 2007 at 10:28 AM

    Can u make ur question clear.

    are you looking for a report to find the unit managers or are you searching for error in the code

    Check this Tcode S_AHR_61016532 this will help you in finding org units with chiefs and org units wihtout cheifs.

    Regards,

    Rao

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      hi

      if it help

      here is table i_t_data and i wont to add for all orgeh which manager manage

      this org btween dates

      Regards

      datafrom datato orgeh org.manager

      19690101 99991231 50002993 00000000

      19690101 99991231 50002994 00000000

      19650101 99991231 50003004 00000000

      20050101 99991231 50003014 00000000

      19690101 99991231 50003018 00000000

      20050101 99991231 50003019 00000000

      20050101 99991231 50003020 00000000

      regards

  • author's profile photo Former Member
    Former Member
    Posted on Sep 19, 2007 at 12:12 PM

    hi frinds

    maybe some one can help

    i reward

    regards

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.