FM to get managers

Hi,
Can anyone know the function module to get the manager of a person in
HR and also FM to know the chief of the organization unit.
Thanks for the help.

Hi,
    Welcome To SDN..
HRCM_ORGUNIT_MANAGER_GET
AND ALSO CHECK
RH_ACT_LEADING_POSITION & RH_STRUC_GET
any way check out this link
Re: Managers in an Org Structure
Org unit head of an org unit of an employee
Regards

Similar Messages

  • How to get managers from org unit?

    Hi Experts,
    Anyone knows how to get managers information from given org unit?
    Thanks

    Hi Shane,
    You need to use two FM's for this :
    Use BBPU_GET_USERS_OF_ORGUNIT to get user IDs of all users of the ORGUNIT
    And then use BBPU_GET_MANAGER_FLAG to get manager flag for each user ID.
    Hope this helps
    Regards
    Vishal

  • VB Script - almost there, get managers samaccountname?

    Howdy,
    I am trying to finish a script and I can't work out how to get the managers sAmAccountName for the users after running the script below.
    I have pulled some of the attributes this pulls out for testing, but it does work and it populates MS SQL DB fine. I am not sure how to get the managers info aside from the DN which I can't use.
    Can anyone help?
    Set objRootDSE = GetObject("LDAP://RootDSE")
    strDNSDomain = objRootDSE.Get("defaultNamingContext")
    strBase = "<LDAP://" & "localdomain" & ">"
    strFilter = "(&(objectCategory=person)(objectClass=user)(company=*))"
    strAttributes = "sAMAccountName,sn,GivenName,distinguishedName,"
    strAttributes = strAttributes & "Department"
    strAttributes = strAttributes & "manager"
    strQuery = strBase & ";" & strFilter & ";" & strAttributes & ";subtree"
    Set adoRecordset = CreateObject("ADODB.Recordset")
    Set adoRecordset.ActiveConnection = adoConnection
    adoRecordset.Properties("Page Size") = 1000
    adoRecordset.Source = strQuery
    adoRecordset.Open
    Do Until adoRecordset.EOF
       SQLRecordset.AddNew
        SQLRecordset.Fields("sAMAccountName") = adoRecordset.Fields("sAMAccountName")
        SQLRecordset.Fields("department") = adoRecordset.Fields("department")
    sDesc = ""
        If IsNull(adoRecordset.Fields("description")) = False Then
            For Each item In adoRecordset.Fields("Description").Value
                   sDesc = sDesc & Trim(item)
            Next
             SQLRecordset.Fields("description") = sDesc
        Else
            SQLRecordset.Fields("description") = Null
        End If
        SQLRecordset.Fields("displayName") = adoRecordset.Fields("displayName")

    Start here:
    https://gallery.technet.microsoft.com/site/search?f%5B0%5D.Type=RootCategory&f%5B0%5D.Value=activedirectory&f%5B0%5D.Text=Active%20Directory&f%5B1%5D.Type=SubCategory&f%5B1%5D.Value=useraccounts&f%5B1%5D.Text=User%20Accounts
    ¯\_(ツ)_/¯

  • FM To get managers name in HR-ABAP

    Hi Experts,
    The scenario is this, we have two Org units A and B, the orgunit B comes under A.
    I have orgunit B's number, with that I want to find its managers name.
    If that org unit B doesn't have any manager, then it should automatically give us the manager name of orgunit A.
    Please let me know are there any Function module to do this.
    Thanks in Advance,
    Nivash.

    HI try to use this.....
    DATA :   v_objid LIKE hrp1001-objid,
               v_sobid LIKE hrp1001-sobid,
               v_pernr LIKE pa0001-pernr,
               v_first LIKE pa0002-nachn,
               v_last  LIKE pa0002-vorna,
              v_name  LIKE pa0002-nachn,
               v_date    type datum.
    *To fetch Selection Screen Date.
      v_date = pn-begda.
      refresh it_hrp1001.
      SELECT begda objid subty sobid FROM hrp1001
        INTO corresponding fields of table it_hrp1001
       WHERE objid = p0001-plans
         AND subty = 'A002'
         AND begda LE v_date.
      if not it_hrp1001[] is INITIAL.
        SORT it_hrp1001 BY begda DESCENDING .
        LOOP AT it_hrp1001 INTO wa_hrp1001.
          v_objid = wa_hrp1001-objid.
          ON CHANGE OF v_objid.
            v_sobid = wa_hrp1001-sobid.
          ENDON.
          CLEAR : wa_hrp1001,v_objid.
        ENDLOOP.
    *Concatinating First Name And Last Name
        SELECT single pernr FROM pa0001
          INTO v_pernr
         WHERE plans = v_sobid.
        SELECT single  vorna nachn FROM pa0002
          INTO (v_first, v_last)
         WHERE pernr = v_pernr.
        CONCATENATE v_first v_last  INTO g_mname SEPARATED BY space.
        clear:   v_objid,
                 v_sobid,
                 v_pernr,
                 v_first,
                 v_last,
                 wa_hrp1001.
      endif.
    Thanks
    Rahul

  • How to get Manager name of a particular BP/User from territory management

    Hi Guys,
    I want to retrieve the Manager name of a particular BP/User from territory management. The manager might be in any territory hierarchy level above the user.
    Please guide.
    Regards,
    Shaili

    Hi Shailip,
    Basically Territory hierarchy is customized based on client's business, from your reply if i understood properly i think your territory has 3 levels and 
    First level : District
    Second level: Area
    Third level: Branch
    when an employee at third level is passed, you need employees assigned to area and district levelwhich are above Branch(in your case managers)
    Solution:  Example
    First level : District - territory length(2 char)
    Second level: Area - - territory length(4 char)
    Third level: Branch- territory length(4 char)
    1. Read the territory hierarchy(which is customized to meet clients requirement) using function module
        CRM_TERRMAN_TERRLEVEL_READ ehich gives territory levels with territory length and territory offset
    2. pass employee(business partner number) to FM  CRM_TERRMAN_TERR_EMP_DETERMINE  and get the branch path id.
    3. Based on territory length for above levels drill down to Area's path id and District's path id and pass those path id's to
    FM CRM_TERRMAN_EMPLOYEE_DETERMINE  to get managers.
    Hope this helps.
    Thanks,
    Priyanka

  • How to show first parameter value in drop down list as a default value dynamically in ssrs report?

    Hi,
    in my ssrs report i have two parameters, accounts and Manager ,there is a cascading between the accounts parameter and manager parameter, as per the cascading we will get managers names based on the account we selected in the accounts parameter,
    my requirement is the first name in the mangers drop down list  has to get selected as default value.
    please help me with this, it is an urgent requirement.
    Thanks in advance,
    Naveen

    Hi NaveenMSBI,
    According to your description, you want to use cascading parameters in the report, if the accounts are selected when you preview the report, the first manager name will be selected from drop down list as the default value. If so, there can be two scenarios:
    • If manager is single-valued parameter, we can get Available Values and Default Values from the same query as below. Then when the accounts are selected, the first manager name will be selected as default value.
    SELECT managerName FROM table_name WHERE accounts IN (@accounts)
    • If manager is multi-valued parameter, we need to use different query for Available Values and Default Values. In this case, please refer to Patrick’s solution.
    For more information about Adding Cascading Parameters, please refer to the following document:
    http://technet.microsoft.com/en-us/library/aa337498(v=sql.105).aspx
    If you have any questions, please feel free to let me know.
    Best Regards,
    Wendy Fu

  • ESS not configured correctly

    Hey All
    We have a netweaver 2004 installation, and are trying to get managers desktop, ESS and Learning systems running. I have been able to get LSM running and can preview any iview component, when it comes to the other two all I get is page cannot be displayed. I am displaying the pages by following this menu path
    portal content >> portal content >> migrated content >> ep5.0>>
    Employee Self Service >> right click on address select open object >>
    hit preview button.
    Windows 2000 OS Oracle backend Java component using integrated ITS.
    Thanks in Advance
    Troy

    No problem.  I have run into this a few times at some of the migrations I have done :).  As for your other question, you don't really HAVE to use a public CA for external access, but it would certainly make your life easier if you did  If
    you use your internal CA then you need to provide users with the Root Cert and instructions on how to import that root certificate into their machines at home/phones.  Too many head aches if you ask me.  I would rather buy a SAN cert from someone
    like GoDaddy and use that since Godaddy is a trusted public CA so htere's nothing they have to do on their end :)

  • How to find out source code of portal

    Hi all,
        I'm working ECC6.0.
        In the portal there is a field managers substitute , when ever manager enteres . managers substitute name will populate.   the portal is constructed long back . it uses jsp.  I found out that portal applicarion calls from the jsp link of another server. i can view only  the application but i want to know where the souce code is available . potal calls the function module or table to get managers substite .i need to find out FM or filed name.
    thanks
    Naveen

    Hi all,
        I'm working ECC6.0.
        In the portal there is a field managers substitute , when ever manager enteres . managers substitute name will populate.   the portal is constructed long back . it uses jsp.  I found out that portal applicarion calls from the jsp link of another server. i can view only  the application but i want to know where the souce code is available . potal calls the function module or table to get managers substite .i need to find out FM or filed name.
    thanks
    Naveen

  • Please help me in this dashboard

    goal= have to create 2 radio buttons (1.sap bw , 2 sap bo) ---> after clicking one of the radio button i have to move to accorden selector in that i have to get categories as manager (ex: if i selected sap bw radio button then i have to get managers in bw as a categories in accorden and with respective lables )
    please help me in this dashboard
    thank u .. umma

    Hey, link the radio button to a cell to record the selection, i.e. understand in SAP BW is selected or SAP BO. Now take a combo box component and map it to the excel range in the picture you have shared. select insertion type as filtered rows and map the seleted items field to the radio button destination cell(or the cell that tells you what is selected - SAP BW or SAP BO). Map the destination of the combo box to a fresh range in the excel and use this same range as the input for the accordion menu.
    According to the selection in the radio button, the values in the accordion menu should change. You may hide the combo box behind the accordion menu itself. 
    Do let me know if you find the solution helpful.
    Thanks,
    Prasanna

  • GPIB read freezing when running vi without debug light ... (it works with the light)

    I have a gpib read that spits out two values at a offset. This is in a loop thats defined by the initial , final and step size parameters. My question is, why does the gpib read freezes (or doesn't exectue; whenever I turn the debug light on(after it's been run), it 'lights' up only till the gpib read and nothing further). I replaced the gpib read with visa read , it doesn't freeze anymore but it only records zeros (when I can clearly see my system outputting some values). Any help would be appreciated.
    *there was a similar topic about debug light and the reasoning was made to be a race condition. but I dont see how my situation is a race condition.
    Thanks,
    kb.
    Solved!
    Go to Solution.
    Attachments:
    racecond.PNG ‏37 KB

    kb003 wrote:
    Cleaning up...for me thats the cleaned up version. I'm still figuring out labview. 
    Stacked sequence made the perfect sense in a 1-2-3 logical reasoning. 
    <snip>
    I wrote my code from an ancient driver set. I figured why to mess with something that's already working. So, I built it all on gpib. 
    This brings up an ancient scrap I have with National Instruments.  Namely, they advertize LabVIEW as something so easy to use, you can dive right in.  Well the truth is, you can dive right in, but it's guaranteed you will be writing horrible code, and much more easily than with any other programming language.
    In reality, you really have to have training, formal (classes) or informal (books on LabVIEW), just like with any other programming language.  Because NI keeps promoting the LabVIEW Falsehood, you get managers that assign newbies to write complex code, and then you have issues like the one the poster has above.
    I'll get off my soapbox now and return you to your local programming, already in progress...
    Bill
    (Mid-Level minion.)
    My support system ensures that I don't look totally incompetent.
    Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.

  • Access Connections - Many APs with same SSID (Again)

    I have a W520 running Access Connections 6.11 (release December 2013) on Windows 7 Pro 64-bit.  Access Connections is still broken in regards to dealing with multiple Access Ponts having the same SSID.  It keeps hoping from one access point to another regardless of signal strength of the AP.  
    The most desirable strategy would be if Access Connections would find and lock on to the best signal strength AP and stay there.  However, it doesn't do that.  It acts almost randomly.  It also keep shifting around.  The rate is almost random as well.  Sometimes it will stay locked on to an AP for up to 10 minutes, at other times it shifts in as little as 30 seconds.
    Other laptops, from other manufacturers like HP, Toshiba, and Apple do NOT exhibit this behavior on our campus.  Other Lenovo machines running Access Connections DO exhibit this behavior.  The problem is NOT machine specific (ie, not hardware or some weird idiosyncracy of the particular W520 i'm posting about).  The problem is Lenovo's Access Connections.  The problem is also not a configuration issue with the campus.  I have a network at home running Airport Extremes all having the same SSID's and the W520 in question does exactly the same behavior there.  Totally different hardware at home vs campus and same behavior.  I cannot change the names of the AP as a fix.  This is not a capability in the configuration of the AP's.  Even if it were, I shouldn't have to do it.  Campuses are often configured in this way.  Campuses that are large commercial users who I believe are the most lucrative Lenovo customers.
    This problem has been going on for literally years with different versions of Access Connections.  Here are two threads in the Lenovo Community I found in under 30 seconds.  Neither was solved correctly.  In other words, Lenovo never fixed the software, and people had to either give up or resort to kludge solutions in their campus configurations.  
    http://forums.lenovo.com/t5/ThinkVantage-Technologies/Is-it-possible-to-default-to-a-specific-Access...
    http://forums.lenovo.com/t5/ThinkVantage-Technologies/Access-Connections-Many-APs-with-same-SSID/m-p...
    Lenovo has actually made the problem progressively worse over time instead of fixing it.  They have done this by removing the abilty to prioritize AP's by MAC address.  Initially, Lenovo allowed you to configure 5 MAC addresses in order.  Then, Lenovo removed that capability making it possible to only give a single MAC address as preferred.  Finally, in recent iterations, Lenovo removed that capability alltogether.  The box is still there in the UI, but it's greyed out.  It is very frustrating to have this kind of thing happen.  The prioritize capability is fundamentally a kludge, but at least it's something to give a bit of a workaround.  Now we don't even have that.
    Can a lenovo engineer please look at this issue and give me a timeline for resolution?
    BTW, It is still not possible to configure Access Connections with a blank SSID either.  I bring this up, because if you're going to fix the Access Connections code for multiple SSID's, you should be aware of the blank SSID problem as well.  I imagine they are both in the same part of the Access Connections codebase, at least from a logical standpoint.
    Thank you.

    I found that there is a setting in the Intel driver (15.9.1.2, released 8/22/2013) for the wireless card (Centrino Advanced-N 6205).  The setting adjusts the "roaming aggressiveness".  I can only guess this means how often the driver goes out and tries to find a "better" signal and/or bandwidth.  The card supports a/b/g so the calculus is complex as to what constitutes "better", and I have no idea how sophisticated the algorithm the driver uses is.
    That said, if I set the "aggressiveness" to the most aggressive setting, things work somewhat better.  They are still not as a good as other wifi managers bundled with competing products (specifically HP, Toshiba, and Apple so far), but it helps.  It does appear that more of the time now, the AP having the best signal appears to be the AP the laptop is attached to.
    Lenovo, please consider that forcing your customers to dig around in arcane driver settings and relying on the whims of driver writers and hardware companies to do things correctly and well, is a recipe for failure.  Your customers are just going to get annoyed and say to their colleagues, "My old Toshiba seemed to do a better job of WiFi connections. I think next time, I'm going to have IT get me one of those again."   And, of course, that colleague will look a lot harder at buying the Toshiba instead of the Lenovo, as well.  Wifi connectivity is a very big deal for people who have to move around - and lets not forget, this is a laptop we're talking about, which is explicitly designed to, well, be moved around.
    I apologize for being so pedantic, but it often takes such measures to get managers in these companies who control programmer time, to take these issues seriously and allocate the programmer resources to fix these problems.
    The problem I am having is still not considered "fixed."  I would very much like to hear any other solutions that work better.  I would love to hear from Lenovo on the matter.  Still waiting.
    Thanks.

  • Connect by nocycle prior issue

    Hi All,
    Below Query results in getting managers and employees with in the levels 1,2 and 3.
    select distinct super.full_name manager,ppf.full_name "Employee", level lvl
    from per_all_assignments_f paf, per_all_people_f ppf, per_person_types ppt, per_all_people_f super
    where ppf.person_id = paf.person_id
    and ppt.person_type_id = ppf.person_type_id
    and ppt.system_person_type in( 'EMP','CWK','OTHER')
    and super.person_id(+) = paf.supervisor_id
    and sysdate between super.effective_start_date and super.effective_end_date
    and sysdate between ppf.effective_start_date and ppf.effective_end_date
    and sysdate between paf.effective_start_date and paf.effective_end_date
    and paf.business_group_id = 81
    start with ppf.employee_number='XXX'--Assume it is CEO
    connect by nocycle prior paf.person_id = paf.supervisor_id
    and level<=3
    what should be thw query if I want to get only for level 2 or level 3 or level 4 etc.
    I tried to with this
    select distinct super.full_name manager,ppf.full_name "Employee", level lvl
    from per_all_assignments_f paf, per_all_people_f ppf, per_person_types ppt, per_all_people_f super
    where ppf.person_id = paf.person_id
    and ppt.person_type_id = ppf.person_type_id
    and ppt.system_person_type in( 'EMP','CWK','OTHER')
    and super.person_id(+) = paf.supervisor_id
    and sysdate between super.effective_start_date and super.effective_end_date
    and sysdate between ppf.effective_start_date and ppf.effective_end_date
    and sysdate between paf.effective_start_date and paf.effective_end_date
    and paf.business_group_id = 81
    start with ppf.employee_number='XXX'--Assume it is CEO
    connect by nocycle prior paf.person_id = paf.supervisor_id
    and level=3
    This results 0 rows. We have records under lelev =3. Is there any other way to write the query to get level 3 or level 4 and so on.
    Help is appreciated.

    Explain Plan
    PLAN_TABLE_OUTPUT
    | Id | Operation | Name | Rows | Bytes | Cost (%CPU)|
    | 0 | SELECT STATEMENT | | 194 | 32204 | 370 (2)|
    | 1 | TABLE ACCESS BY INDEX ROWID | FND_LOOKUP_VALUES | 1 | 52 | 4 (0)|
    |* 2 | INDEX RANGE SCAN | FND_LOOKUP_VALUES_U1 | 1 | | 3 (0)|
    | 3 | SORT UNIQUE | | 194 | 32204 | 369 (1)|
    | 4 | NESTED LOOPS | | | | |
    | 5 | NESTED LOOPS | | 194 | 32204 | 368 (1)|
    |* 6 | HASH JOIN RIGHT OUTER | | 101 | 12827 | 166 (2)|
    | 7 | VIEW | HR_LOCATIONS | 2 | 14 | 5 (0)|
    | 8 | NESTED LOOPS | | 2 | 34 | 5 (0)|
    |* 9 | TABLE ACCESS FULL | HR_LOCATIONS_ALL | 1 | 9 | 5 (0)|
    |* 10 | INDEX UNIQUE SCAN | HR_LOCATIONS_ALL_TL_PK | 1 | 8 | 0 (0)|
    |* 11 | HASH JOIN | | 101 | 12120 | 160 (1)|
    |* 12 | TABLE ACCESS FULL | PER_PERSON_TYPES | 20 | 240 | 6 (0)|
    | 13 | NESTED LOOPS | | | | |
    | 14 | NESTED LOOPS | | 103 | 11124 | 154 (1)|
    |* 15 | HASH JOIN OUTER | | 54 | 3348 | 46 (3)|
    | 16 | VIEW | | 54 | 1674 | 33 (0)|
    |* 17 | FILTER | | | | |
    |* 18 | CONNECT BY WITH FILTERING | | | | |
    | 19 | TABLE ACCESS BY INDEX ROWID | PER_ALL_ASSIGNMENTS_F | | | |
    | 20 | NESTED LOOPS | | 27 | 2052 | 38 (0)|
    | 21 | NESTED LOOPS | | 12 | 852 | 26 (0)|
    | 22 | NESTED LOOPS | | 6 | 300 | 20 (0)|
    | 23 | TABLE ACCESS BY INDEX ROWID| PQH_ROLES | 1 | 22 | 1 (0)|
    |* 24 | INDEX UNIQUE SCAN | PQH_ROLES_UK | 1 | | 0 (0)|
    |* 25 | TABLE ACCESS BY INDEX ROWID| PER_PEOPLE_EXTRA_INFO | 6 | 168 | 19 (0)|
    |* 26 | INDEX RANGE SCAN | PER_PEOPLE_EXTRA_INFO_FK1 | 179 | | 2 (0)|
    |* 27 | INDEX RANGE SCAN | PER_PEOPLE_F_PK | 2 | 42 | 1 (0)|
    |* 28 | INDEX RANGE SCAN | PER_ASSIGNMENTS_F_N12 | 2 | 10 | 1 (0)|
    | 29 | NESTED LOOPS | | | | |
    | 30 | CONNECT BY PUMP | | | | |
    |* 31 | FILTER | | | | |
    | 32 | TABLE ACCESS BY INDEX ROWID | PER_ALL_ASSIGNMENTS_F | 54 | 1836 | 33 (0)|
    |* 33 | INDEX RANGE SCAN | PER_ASSIGNMENTS_F_N10 | 36 | | 2 (0)|
    | 34 | TABLE ACCESS BY INDEX ROWID | PER_ASSIGNMENT_EXTRA_INFO | 206 | 6386 | 12 (0)|
    |* 35 | INDEX RANGE SCAN | PER_ASSIGNMENT_EXTRA_INFO_FK2 | 206 | | 2 (0)|
    |* 36 | INDEX RANGE SCAN | PER_PEOPLE_F_PK | 2 | | 1 (0)|
    | 37 | TABLE ACCESS BY INDEX ROWID | PER_ALL_PEOPLE_F | 2 | 92 | 2 (0)|
    |* 38 | INDEX RANGE SCAN | PER_PEOPLE_F_PK | 2 | | 1 (0)|
    | 39 | TABLE ACCESS BY INDEX ROWID | PER_ALL_PEOPLE_F | 2 | 78 | 2 (0)|
    Predicate Information (identified by operation id):
    2 - access("LOOKUP_TYPE"='MF_HR_APPROVAL_LIMITS' AND "LOOKUP_CODE"=:B1 AND "LANGUAGE"='US')
    filter("LOOKUP_CODE"=:B1 AND "LANGUAGE"='US')
    6 - access("PAF"."LOCATION_ID"="HL"."LOCATION_ID"(+))
    9 - filter(NVL("LOC"."BUSINESS_GROUP_ID",NVL("HR_GENERAL"."GET_BUSINESS_GROUP_ID"(),(-99)))=NVL("HR_GE
    NERAL"."GET_BUSINESS_GROUP_ID"(),NVL("LOC"."BUSINESS_GROUP_ID",(-99))))
    10 - access("LOC"."LOCATION_ID"="LOT"."LOCATION_ID" AND "LOT"."LANGUAGE"=USERENV('LANG'))
    11 - access("PPT"."PERSON_TYPE_ID"="PPF"."PERSON_TYPE_ID")
    12 - filter("PPT"."SYSTEM_PERSON_TYPE"='CWK' OR "PPT"."SYSTEM_PERSON_TYPE"='EMP' OR
    "PPT"."SYSTEM_PERSON_TYPE"='OTHER')
    15 - access("PAF"."ASSIGNMENT_ID"="PAEI"."ASSIGNMENT_ID"(+))
    17 - filter("EFFECTIVE_START_DATE"<=SYSDATE@! AND "EFFECTIVE_END_DATE">=SYSDATE@! AND LEVEL>6)
    18 - access("SUPERVISOR_ID"=PRIOR "PERSON_ID")
    filter(LEVEL<=7)
    24 - access("ROLE_NAME"='CEO')
    25 - filter("RLS"."ROLE_ID"=TO_NUMBER("PEI"."PEI_INFORMATION3"))
    26 - access("INFORMATION_TYPE"='PQH_ROLE_USERS')
    27 - access("PEI"."PERSON_ID"="PPF"."PERSON_ID" AND "PPF"."EFFECTIVE_END_DATE">=SYSDATE@! AND
    "PPF"."EFFECTIVE_START_DATE"<=SYSDATE@!)
    filter("PPF"."EFFECTIVE_END_DATE">=SYSDATE@!)
    28 - access("PERSON_ID"="PPF"."PERSON_ID")
    31 - filter(LEVEL<=7)
    33 - access("SUPERVISOR_ID"=PRIOR "PERSON_ID")
    35 - access("PAEI"."INFORMATION_TYPE"(+)='MF_HR_APPROVAL_LIMITS')
    36 - access("PPF"."PERSON_ID"="PAF"."PERSON_ID" AND "PPF"."EFFECTIVE_END_DATE">=SYSDATE@! AND
    "PPF"."EFFECTIVE_START_DATE"<=SYSDATE@!)
    filter("PPF"."EFFECTIVE_END_DATE">=SYSDATE@!)
    38 - access("SUPER"."PERSON_ID"="PAF"."SUPERVISOR_ID" AND "SUPER"."EFFECTIVE_END_DATE">=SYSDATE@! AND
    "SUPER"."EFFECTIVE_START_DATE"<=SYSDATE@!)
    filter("SUPER"."EFFECTIVE_END_DATE">=SYSDATE@!)
    Note
    - 'PLAN_TABLE' is old version

  • TO setup Cold Failover in ESP Cluster

    Hi,
    I created two nodes (node1 and node2) and started in defferent machines, node1 in vewin764SA016(1st machine) and node2 in vewin764SA046(2nd machine)(I have attached both files).
    I created an ESP project which has input window attached to XML Input Adapter.
    I setup cluster configuration in CCR file as follows (I have attached CCR file also. I could not able to attach .ccr, so it change extension to txt):
    <?xml version="1.0" encoding="UTF-8"?>
    <Configuration xmlns="http://www.sybase.com/esp/project_config/2010/08/">
      <Runtime>
      <Clusters>
          <Cluster name="esp://vewin764SA016:19011" type="remote">
            <Auth>user</Auth>
            <Username encrypted="false">sybase</Username>
            <Password encrypted="false">sybase</Password>
            <Rsakeyfile></Rsakeyfile>
      <Managers>
      <Manager>vewin764SA016:19001</Manager>
      <Manager>vewin764SA046:19002</Manager>
      </Managers>
          </Cluster>
        </Clusters>
        <Bindings>
          <Binding name="Battery_Life_Input_Adapter_window">
            <Cluster>esp://vewin764SA016:19011</Cluster>
            <Workspace>test</Workspace>
            <Project>test</Project>
            <BindingName>b1</BindingName>
            <RemoteStream>remote1</RemoteStream>
            <Output>false</Output>
          </Binding>
        </Bindings>
        <AdaptersPropertySet>
          <PropertySet name="Atom Feed Input">
            <Property name="URL"></Property>
          </PropertySet>
        </AdaptersPropertySet>
      </Runtime>
      <Deployment>
        <Project ha="false">
          <Options>
            <Option name="time-granularity" value="5"/>
            <Option name="debug-level" value="4"/>
          </Options>
          <Instances>
            <Instance>
              <Failover enable="true">
                <FailureInterval>120</FailureInterval>
                <FailuresPerInterval>5</FailuresPerInterval>
              </Failover>
              <Affinities>
                <Affinity charge="positive" strength="strong" type="controller" value="node1"/>
                <Affinity charge="positive" strength="weak" type="controller" value="node2"/>
              </Affinities>
              <Affinities/>
            </Instance>
          </Instances>
        </Project>
      </Deployment>
    </Configuration>
    I added project to node1 using following command and started the project
    esp_cluster_admin --uri=esp://vewin764SA016:19011 --username=sybase --password=sybase --add_project --project-name=test --workspace-name=test --ccx=test.ccx --ccr=test.ccr
    Project started in both machines and both getting data.
    As per ESP document: "If cold failover is enabled, a failover occurs when a failed project switches to another server to continue processing."
    But in my case project is running in both the nodes and both getting data.
    I tried all possible combinations for Affinity attributes charge and strength(positive/negative, strong/weak). But it did not work out.
    How can I set up a cluster such that when i add a project, it should start running on one node and when that node goes down, it should bring up second node and start running on that.
    Thanks
    Shashi

    Hi Shashi,
    Reviewing the configuration of your ccr file, you've got
              <Affinities>
                <Affinity charge="positive" strength="strong" type="controller" value="node1"/>
                <Affinity charge="positive" strength="weak" type="controller" value="node2"/>
              </Affinities>
              <Affinities/>
    Just note, that in your set-up, you've set strong and positive for node1. This means that it will only run on node1.So if your node1 is down, the project will not start up on node2. Is that what you are trying to accomplish?
    "</Affinities>" - that fifth line there is extra. I don't think it is harming anything though.
    I am assuming that you are using Studio to see the that the "Project started in both machines and both getting data".
    There is an outstanding New Feature Request CR for Studio to support HA and failover. Studio is really not compatible with HA.  Studio makes it look like there are multiple instances of the project running when in fact there is only one instance running. Studio will start getting errors if the project crashes and is failed over to the secondary node.  I can’t really recommend using Studio at all when dealing with HA:
    CR 732974 - Request for Studio support of HA and failover.
    To confirm that there is only one instance of the project running, I look at esp_cluster_admin:
    $ esp_cluster_admin --uri esp://bryantpark:19011 --username=sybase
    Password:
    > get managers
    Manager[0]:     node1@http://bryantpark.sybase.com:19011
    Manager[1]:     node2@http://bryantpark.sybase.com:19012
    > get controllers
    Controller[0]:  node1@http://bryantpark.sybase.com:19011
    Controller[1]:  node2@http://bryantpark.sybase.com:19012
    > get projects
    =============================
    Workspace:                    test
    Project:                      test
    Instance Count:               1
        ----------- Instance Details -----------
        Instance Name:                default
        Controller Name:              node1
        Current Status:               started-running
        Requested Status:             started-running
        Failure Interval:             120
        Failures Per Interval:        5
            -------------- Affinities --------------
            Affinity Type:                CONTROLLER
            Affinity Charge:              POSITIVE
            Affinity Strength:            STRONG
            Affinity Subject:             node1
            Affinity Type:                CONTROLLER
            Affinity Charge:              POSITIVE
            Affinity Strength:            WEAK
            Affinity Subject:             node2
    >
    The output from "get projects" shows that there are two active managers and controllers, and that the single instance is running from the controller named node1.
    Next, I run the "get project" command, and it shows me the Pid:
    > get project test/test
    Workspace:                    test
    Project:                      test
        ------------------ Instance : 0 ------------------
        Instance Id:                  Id_2000003_1393600620713
        Command Host:                 bryantpark.sybase.com
        Command Port:                 44905
        Gateway Host:                 bryantpark.sybase.com
        Gateway Port:                 41162
        Sql Port:                     47244
        SSL Enabled:                  false
        Big Endian:                   false
        Address Size:                 8
        Date Size:                    8
        Money Precision:              4
        Pid:                          20637
        Topology Ignored:             false
        Timer Interval:               5
        Active-Active:                false
    I run these Linux commands that also confirm to me that I have only one instance running:
    $ ps -ef | grep esp_server
    alices   19963 19961  1 09:45 pts/0    00:00:27 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-node node1.xml --cluster-log-properties node1.log.properties
    alices   20243 20241  1 09:59 pts/1    00:00:15 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-node node2.xml --cluster-log-properties node2.log.properties
    alices   20637 19963  0 10:16 ?        00:00:00 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-container --cluster-container-id Id_2000003_1393600620713 --log-to 4
    alices   20729 18201  0 10:18 pts/2    00:00:00 grep esp_server
    From here, I see that pid 20637's parent pid is 19963, which is the pid for node1 server.
    Next, I kill the active manager and the project to simulate a catastrophic failure:
    $ kill -9  20637 19963
    Due to the affinities, no failover happens to node2:
    $ ps -ef | grep esp_server
    alices   20243 20241  1 09:59 pts/1    00:00:17 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-node node2.xml --cluster-log-properties node2.log.properties
    alices   20764 18201  0 10:21 pts/2    00:00:00 grep esp_server
    Next, I use a different ccr file that does not have affinities configured.
    From esp_cluster_admin, I stop and remove the test/test project and then re-run using the modified ccr that has no affinities.
    $ esp_cluster_admin --uri esp://bryantpark:19012\;bryantpark:19011 --username=sybase
    Password:
    > remove project test/test
    [done]
    > add project test/test bin/test.ccx test-without-affins.ccr
    [done]
    > start project test/test
    [done]
    > get projects
    =============================
    Workspace:                    test
    Project:                      test
    Instance Count:               1
        ----------- Instance Details -----------
        Instance Name:                default
        Controller Name:              node2
        Current Status:               started-running
        Requested Status:             started-running
        Failure Interval:             120
        Failures Per Interval:        5
    This time, the project started on node2.
    > get project test/test
    Workspace:                    test
    Project:                      test
        ------------------ Instance : 0 ------------------
        Instance Id:                  Id_1000003_1393601774031
        Command Host:                 bryantpark.sybase.com
        Command Port:                 46151
        Gateway Host:                 bryantpark.sybase.com
        Gateway Port:                 36432
        Sql Port:                     50482
        SSL Enabled:                  false
        Big Endian:                   false
        Address Size:                 8
        Date Size:                    8
        Money Precision:              4
        Pid:                          21422
        Topology Ignored:             false
        Timer Interval:               5
        Active-Active:                false
    >
    The pid is 21422.
    $ ps -ef | grep esp_server
    alices   21213 21211  4 10:33 pts/0    00:00:07 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-node node1.xml --cluster-log-properties node1.log.properties
    alices   21282 21280  4 10:33 pts/1    00:00:07 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-node node2.xml --cluster-log-properties node2.log.properties
    alices   21422 21282  1 10:36 ?        00:00:00 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-container --cluster-container-id Id_1000003_1393601774031 --log-to 4
    alices   21500 18201  0 10:36 pts/2    00:00:00 grep esp_server
    Pid 21422's parent pid is 21282, which is the pid for node2 server.
    Kill the project and node2:
    $ kill -9  21422 21282
    $ ps -ef | grep esp_server
    alices   21213 21211  4 10:33 pts/0    00:00:08 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-node node1.xml --cluster-log-properties node1.log.properties
    alices   21505 21213 12 10:36 ?        00:00:00 /work/alices/esp514/ESP-5_1/bin/esp_server --cluster-container --cluster-container-id Id_2_1393601813749 --log-to 4 --clus
    alices   21578 18201  0 10:36 pts/2    00:00:00 grep esp_server
    The project automatically fails over now to node1.
    > get managers
    Manager[0]:     node1@http://bryantpark.sybase.com:19011
    > get controllers
    Controller[0]:  node1@http://bryantpark.sybase.com:19011
    > get projects
    =============================
    Workspace:                    test
    Project:                      test
    Instance Count:               1
        ----------- Instance Details -----------
        Instance Name:                default
        Controller Name:              node1
        Current Status:               started-running
        Requested Status:             started-running
        Failure Interval:             120
        Failures Per Interval:        5
    Thanks,
    Alice

  • Manipulate CSV File Data

    Hello,
    Our Active Directory structure only lists the person's manager in the format of an email address. After running a Get-ADUser command and exporting its data to a csv file. I want to import the csv file which will be in the format shown below, then manipulate
    it, so the manager1 field is converted to the relevant objectGUID and populated in the Manager_objectGUID field.
    I'm completely new to PowerShell so any assistance would be much appreciated.
    Thanks
    Stuart

    $OldCSV = "C:\OldADUsers.csv"
    $NewCSV = "C:\NewADUsers.csv"
    Add-Content $OldCSV "objectGUID,mail,givenName,sn,manager1,Manager_objectGUID"
    Add-Content $OldCSV "7c1be78f,[email protected],Mickey,Mouse,,"
    Add-Content $OldCSV "982874ab,[email protected],Donald,Duck,[email protected],"
    $ADUsers = Import-CSV $OldCSV
    # collect managers
    $Managers = @{}
    ForEach ($ADUser in $ADUsers)
    $Managers.Add($ADUser.Mail,$ADUser.ObjectGUID)
    # Get Managers
    ForEach ($ADUser in $ADUsers)
    IF ($ADUser.manager1 -NE "")
    If ($Managers[$ADUser.manager1] -NE $Null)
    $ADUser.Manager_objectGUID = $Managers[$ADUser.manager1]
    $ADUsers | Export-CSV $NewCSV
    Get-Content $NewCSV
    Gives this output
    #TYPE System.Management.Automation.PSCustomObject
    "objectGUID","mail","givenName","sn","manager1","Manager_objectGUID"
    "7c1be78f","[email protected]","Mickey","Mouse","",""
    "982874ab","[email protected]","Donald","Duck","[email protected]","7c1be78f"

  • How do I use Get-ADUser to get just the Managers attribute? And then get rid of duplicates in my array/hash table?

    Hello,
          I am trying to just get the Managers of my users in Active Directory. I have gotten it down to the user and their manager, but I don't need the user. Here is my code so far:
    Get-ADUser-filter*-searchbase"OU=REDACTED,
    OU=Enterprise Users, DC=REDACTED, DC=REDACTED"-PropertiesManager|SelectName,@{N='Manager';E={(Get-ADUser$_.Manager).Name}}
    |export-csvc:\managers.csv-append 
    Also, I need to get rid of the duplicate values in my hash table. I tried playing around with -sort unique, but couldn't find a place it would work. Any help would be awesome.
    Thanks,
    Matt

    I would caution that, although it is not likely, managers can also be contact, group, or computer objects. If this is possible in your situation, use Get-ADObject in place of Get-ADUser inside the curly braces.
    Also, if you only want users that have a manager assigned, you can use -LDAPFilter "(manager=*)" in the first Get-ADUser.
    Finally, if you want all users that have been assigned the manager for at least one user, you can use:
    Get-ADUser
    -LDAPFilter "(directReports=*)" |
    Select @{N='Manager';E={ (Get-ADUser
    $_.sAMAccountName).Name }}
    -Unique | Sort Manager |
    Export-Csv .\managerList.csv -NoTypeInformation
    This works because when you assign the manager attribute of a user, this assigns the user to the directReports attribute of the manager. The directReports atttribute is multi-valued (an array in essence).
    Again, if managers can be groups or some other class of object (not likely), then use Get-ADObect throughout and identify by distinguishedName instead of sAMAccountName (since contacts don't have sAMAccountName).
    Richard Mueller - MVP Directory Services

Maybe you are looking for

  • "A plugin is needed to display this content", how do I get my computer to do this?

    I am trying to open a video file for my online class. When I click on the file, a gray box appears and reads "a plugin is needed to display this content". How do I get my computer to open the video. I have a MAC and zero knowledge of how to fix probl

  • Flex strings never cleared from the memory

    I have this weird problem for a while and try to solve it to look up on the net for proper solution but still I am clueless. When I check my application's memory usage with flex profiler (4.6) the portion of String keep increasing and eventually reac

  • Universal Dock remote capabilities

    Are you able to use the remote that comes with the Universal Dock to also control the computer it's hooked up to? I mainly want to control simple functions of DVD Player with it. I have a 2009 aluminum iMac.

  • OS X 10.10.2 Server 4.0.3 Wiki User Login Issue

    I have an Apple wiki that seems to be running fine for all but one user. Now, when that user tries to login it just sits there and does not process the username or password. When you go to All People that user is no longer listed there. We authentica

  • Firmware issue updating from 10.2.8 to 10.4

    I'm trying to update an old 400Mhz iMac from 10.2.8 to 10.4 but I can't even get started cause it says I need to update the firmware. But when I run the software updater it says I'm all up to date. What do I need to do?