How to restrict user to enter unique names in numbered list?


My requirement is to create numbered list and to restrict user to enter duplicate values for display name property. Please assist how can I achieve this functionality?



  • Hi @bhubeshrana ,


    You can create one module with only a number list as your dimension & add two line items for display name & to check duplicate here.





    hope this will helps




  • @bhubeshrana 

    Possibly you cannot restrict or prevent the user to enter duplicate names in the numbered list as this is one of its characteristic.

    You can highlight the duplicate names as @Akhtar.shahbaz has shown. This might act as a warning sign for the end user.





  • One way to do it so to use the name as the code at point of insertion this should prevent the same name from being applied in the numbered list

  • You can use Code in numbered lists to enter names, The numbered list property itself will restrict on entering duplicate values. You can also set Display name property to show Code.



    Now, according to image shown above if I try to repeat "User 5", Anaplan throws an error!




    Although if you want to warn user when they enter duplicate name:

    1. Use ISFIRSTOCCURANCE to check if the entry holds unique display name or not.

    2. Make another line item to put comments like "Try different Name" by using If Then Else functionality when the name is repeated.



    Hope it helps!

  • @bhubeshrana 


    Quick question:

    • why does the list need to be a numbered list if you are having to restrict user input to not duplicate the members?  As @anand.shekhawat stated, having duplicate members as the display name is one of the main characteristics of a numbered list.

    Now, if it has to be a numbered list and the requirement is to not allow users to enter duplicate values, I would potentially go down this route.

    • Create a "flat" list with valid values, like Promotions Flat
    • The Display Name should be formatted as Text.  In the SYS module storing the logic, create a line item with the formula Finditem(Promotions Flat, Display Name).  Name it Add Promotion
    • Create a Boolean line item called Load? with the formula Isblank(Add Promotion)
    • create a view, using Load? as the filter.
    • Create an action to load the new member to the list
    • Create another view using Load? as the filter and call the view Load to Promotions Flat.  You need this view because you cannot use the same view in multiple actions within a process.
    • Create a Process adding the above two actions (loading to the list, loading to Promotions Flat)


    Hope this helps,