4 Replies Latest reply on Nov 9, 2018 1:57 PM by florian1

    How to avoid multiple entries in picklists ?

    m.kasper Apprentice

      Hello all,

       

      I have a picklist in which multiple entries are listed. How can I avoid to list multiple entries in the list displayed? QWith an SQL query, I would use a "distinct" keyword, but within the picklist configuration, I could not find anything.

      Is there a hdden trick?

      Do I need to go via constraints? If so, which functions?

      Help is highly appreciated, a newbe is calling

        • 1. Re: How to avoid multiple entries in picklists ?
          florian1 Expert

          I have had the same issue. The only (easiest) solution for me:

          Create/Use validation business objects and use validation constraints for the fields.

           

          Constrain your picklist with the source object and you're fine.

          • 2. Re: How to avoid multiple entries in picklists ?
            monomack Rookie

            Hei Florian,

            what definition of validation constraints you have used (Syntax=?

             

            Thanks

             

            Mono

            • 3. Re: How to avoid multiple entries in picklists ?
              SusanJS Specialist

              What is the source of the pick list?  If the source is a pure validation object, you control it in the object by making the field that the pick list uses to display and save, unique.

               

              If the source is another object where the display field cannot be unique, I created a unique field that combines two fields together that will make the record unique.  For example, locations.  We identify locations by function as well as by address and one location may serve multiple functions.  So, to identify and prevent duplicate entries, I created a field that stores the concatenated information of the location name plus the function code (by business rule) and forced it to be unique.  So, while the location name could be the same as another record, the combination of the name + function must be unique and this is the field that the pick list uses in other objects.  (i.e. ABC Hospital functions as a hospital, but there is a data center located inside.  We wanted to be able to identify it also as a data center so the two unique listings would be "ABC - Hospital" and "ABC - DataCenter".

               

              Not sure if this helps your issue, but here are two options.

              1 of 1 people found this helpful
              • 4. Re: How to avoid multiple entries in picklists ?
                florian1 Expert

                Post converted to PDF and attached for migration.

                2 of 2 people found this helpful