This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

SAP Connector - Authomatic creation of Default Mail and Default Phone

Hi All,

When I create a new SAP User I need to popolate the Default Email and the Default Phone from data contained on Person employee.

The SAP Email and SAP Phones are on  different tables of SAP User.

How is it possible to put these values authomatically when a employee is selected and the SAP User is full managed ?

Thank you very much and best regards

Ermes

Parents
  • Hi Ermes,

    You can assign an account definition to your person. Then the process SAP_PersonHasTSBAccountDef_Autocreate_SAPUser will take care of generating the SAP Email and SAP Phone.

    Your welcome,
    Tomi

  • Hi Tomi,

    I am came back on this.

    I checked my SAP Template to analyse why the Default Email address is not set.

    The column "SMTPAddr" on SAPComSMTP table has the following template:

    If Not CBool(Connection.Variables("FULLSYNC")) AndAlso $IsDefault:Bool$ Then
        Select Case ($FK(UID_SAPUser).FK(UID_TSBBehavior).ITDataUsage:Int$)
            Case 0:'do not get data from employee
            Case -1:'fill property initially from the employee
                If Not $[IsLoaded]:Bool$ Then
                    Value = $FK(UID_SAPUser).FK(UID_Person).DefaultEmailAddress$
                End If
            Case 1:'update property depending on employee
                 If $FK(UID_SAPUser).FK(UID_Person).DefaultEmailAddress$ <> "" AndAlso $IsDefault:Bool$ Then
                    'remove of DefaultEmailAddress means delete the complete entry - handled by process "SAP_Person_Update_CommunicationData"
                    Value = $FK(UID_SAPUser).FK(UID_Person).DefaultEmailAddress$
                End If
        End Select
    End If

    The template is a standard template of the SAP Conenctor.

    When I create a new SAP User, I select for the Account Definition and also I select the "full management" option, but the Default mail window is empty.

    What is my error ?

    Thank you very much and best regards

    Ermes

  • Hi Markus,

    After some test I have the following situation:

    After selection of Person, Account Definition, FullManaged the SAP TAB "Email adresses" is empty.

    I must click on "Add" button to insert a new line and the Email Address is retrived by the template.

    This is a manual step, but cannot be used on automatic creation using the account definition.

    Best regards

    Ermes

  • Hi,

    as the email address is stored in a different object as the sap user the shown behavior is by design. The ootb process started when you assign an account definition to a person, automatically creates this new entry in that additional table for the new sap user like you did in the Manager by pressing the plus.

    The process that does that is called SAP_PersonHasTSBAccountDef_Autocreate_SAPUser.

Reply
  • Hi,

    as the email address is stored in a different object as the sap user the shown behavior is by design. The ootb process started when you assign an account definition to a person, automatically creates this new entry in that additional table for the new sap user like you did in the Manager by pressing the plus.

    The process that does that is called SAP_PersonHasTSBAccountDef_Autocreate_SAPUser.

Children
  • Hi Markus,

    I am sorry, but I whould like to be sure to understand.

    The SAP_PersonHasTSBAccountDef_Autocreate_SAPUser  process create a new SAP user object. This is clear.

    What is not clear is the new object for mail or phone that is not added by this process. There is a way to add a mail object authomatically ?

    If not, I must implement an "on saved" step that create the mail and phone objects after the save of SAP User object.

    What do you suggest ?

    Thank you very much and best regards

    Ermes

  • If you take a look at the process you will detect a process step Create EMail address for account that will be generated if the assigned Person of the SAP User has its default email address set. This process step then creates the SAPComSMTP entry.

  • Hi Markus,

    I follow the process "Create Mail adress for Account" that start from process "SAP_PersonHasTSBAccountDef_Autocreate_SAPUser".

    The job "SAP_PersonHasTSBAccountDef_Autocreate_SAPUser" has a generation condition. The value of generation condition is:

    Value = $FK(UID_Person).CentralSAPAccount$<>"" _
        AndAlso $FK(UID_TSBAccountDef).UID_DialogTableAccountType$ = "SAP-T-SAPUser"

    If you check the value "SAP-T-SAPUser"  on  $FK(UID_TSBAccountDef).UID_DialogTableAccountType$  is not valid.  The similar value may be "SAPUser".

    May be that the process doesn't start and doesn't create the default mail ?

    Thank you very much and best regards,

    Ermes

  • SAP-T-SAPUser is the UID_DialogTable of the table SAPUser so this GenCondition is correct assuming that your account definition is configured correctly.

    By the way, the gen. condition is assigned to the process itself and not to the single process step that creates the default mail.