SAP Knowledge Base Article - Public

3339626 - Duplicate Username change error

Symptom

When you try to change the username via basic import, via manage users, via people profile or via API, you face the errors below :

  • The following users were not imported because the username already exists in the system (Via basic import)
  • Username already exist, please choose another one (Via Manage users)
  • Invalid username. Please choose another (Via People Profile)
  • DUPLICATE_USERNAME : Failed to add/update user [XXXX] "XXX YYYYY" (N/A;N/A;N/A): Duplicate Username - "XXXX" (Via API)

"Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental."

    Environment

    SAP SuccessFactors HCM

    Reproducing the Issue

    Reproducing via Basic Import

    1. Request the document used to import via basic import
    2. Access the instance
    3. Go to Import Employee Data 
    4. Select basic import 
    5. Try to import
    6. Error : The username exists in the system

    Reproducing via Manage user

    1. Go in Admin Center;
    2. Click in Update User Information > Manage User;
    3. Search and select a user;
    4. Try to change the Username field and click Save;
    5. You received an error Username already exist, please choose another one;

    Reproducing via People Profile

    1. Access the instance
    2. Search for the user
    3. In the people profile try to change the username
    4. Invalid username. Please choose another 

    Reproducing Via API (handled by Integrations team)

    • Entity used - User (SFAPI)
    • Operation - Upsert

    1. Let us create a User as shown below.

    dup1_edit.jpg

    We can see that a new user is created in the system (Successfactors)

    2) Now, Change the username from "abc" to "123"

    dup2_edit.jpg

    We can observe that the API call has an error status and the Upsert operation was not successful.

    Cause

    This error indicates that there is a user in the system already using the username you would like to use. To resolve the issue, you need to find the duplicated user and change it's username so then you will be able to use it again.

    • For the error during basic import, manage users and API, please refer to the resolution section to check the duplicated users in the system.
    • For the error on People Profile, please note that username should not be edited from the People Profile UI, as it may lead to inconsistent behavior and application errors. Refer to article 2686245 for further information, and check the note in the people profile Help Portal section covering permissions on employee data.

    Resolution

    NoteIf "Enable Non-Case-Sensitive Username" is enabled for your instance you cannot import users with the same username for example if "ABC" (UPPERCASE) exists, you cannot import "abc" (lowercase). You can refer to the KBA 3501119 for more details.

    You can firstly run the following check tool and quick fix for legacy dirty data fix: 

    • Admin Center > Check Tool > Run the following two checks: 

    1

    User Management OrphanPersonGOs 

    2

    User Account ManagementOrphanAccountCheckExecutor 

     

    If you continue to face the error, then you need to find the duplicated user in the system and change it's username. See below the steps to find it in your system: 

    1. Data Inspector

    • Admin Center > Data Inspector > Select table "Table_USERS_SYSINFO" > search for the username then

    2. Run the Check Tool - Check if the username is appearing as duplicated 

    • Admin Center -> Check tool -> User Management - Select "There are no duplicate usernames in the case-insensitive mode" -> Run Checks
    • The output will share the list of duplicate usernames including (Username, Userid and User status)    

    3. Check UDF file

    • Admin Center > Employee Export > Export user file > search for the username
    • Note: Be careful if your data contains leading zeros. In this case, please choose an editor that does not strip out any values. Example: Excel can make 000123 look like 123 making it impossible to find the duplicate  user.

         

    4 . Manage Login Accounts

    • Admin Center > Manage Login Accounts > Search for the username
      • If the duplicate username is under Login name for another user, follow the steps below: 
        • Change the duplicated user via employee import to be the same as the login name
        • Then change it back to the previous username that it should be
        • The desired username will then be available to be used
                
      • See example below:
              

    However, if no results are found on any of the steps above, we will need to engage the engineering team to run a script to clear the data issue, the customer approval will be needed to proceed.

    See Also

    Keywords

    The username exists in the system, Invalid username. Please choose another, change, username, duplicate, duplicated, import, already exists, sf, SF, successfactors. , KBA , LOD-SF-PLT-UIM , Employee Import Issues , Problem

    Product

    SAP SuccessFactors Platform all versions

    Attachments

    Pasted image.png