You need to sign in to do that
Don't have an account?

Restrict the Duplicates to Entering through Dependent Picklist.!
I created a custom Object "Location" , all are 3 picklists and each other dependent picklists hirarchely.

I am getting Duplication entries from these fields.
when i select HeadQuarter there can be multiple Areas should be enter but once i select one Area in one HeadQuarter,
the selected Area should not save again in the record .
To avoid this which criteria should i follow,
Workflow
Validation Rule
Trigger
Which one is suitable and how.
Is there any other Good Apporach .
I am getting Duplication entries from these fields.
when i select HeadQuarter there can be multiple Areas should be enter but once i select one Area in one HeadQuarter,
the selected Area should not save again in the record .
To avoid this which criteria should i follow,
Workflow
Validation Rule
Trigger
Which one is suitable and how.
Is there any other Good Apporach .
You can use an UNIQUE text field and update it through workflow, by this you can avoid duplicate records
Create a text field as Unique field
Create a workflow to update this field when created and everytime edited
update the field with 'HeadQuarter__c+Area__c'
Thanks
All Answers
You can use an UNIQUE text field and update it through workflow, by this you can avoid duplicate records
Create a text field as Unique field
Create a workflow to update this field when created and everytime edited
update the field with 'HeadQuarter__c+Area__c'
Thanks
You not getting my point i think so.
From the above image those picklists are Dependent picklists, so when i select HeadQuarter it will contain the related Areas in Area Picklist Field.
So here my requirement is
Ex: Karimnagar --------> HeadQuarter
Areas (Picklist): Ramagundam
Peddapally
Huzurabad
Kamalapur etc...
now i select Karimnagar and Ramagundam, and Save the record.
Karimnagar and Peddapally and Save the record.
Karimnagar and Huzurabad and Save the record.
Karimnagar and Ramangundam and Save the record -------- This record i don't want to Save again, for that what is the solution.
Awaiting for your Answer.
Thank You.
try the suggested process
as unique field do not allow duplicate values it throws error before saving the record
if Karimnagar and Ramagundam are chosen for record, the unique field will be updated as 'KarimnagarRamagundam' if you follow the suggested process
so if you try to create a new record with same values, it will stop you with an error
please catch me on abatini27@gmail.com i am online now.
Go to custom fields of that object
Click new
Select text data type and proceed by providing some label and name for it and choose unique check box there case insensitive
Go to workflow rules create new
And choose the object
Give some name choose
Created and every time its edited
Entry criteria if formula
And type TRUE in the formula editor
Click next
Choose a workflow action and create a field update
Choose the unique filed you have created
Choose the formula editor
There enter your first picklist api name and add + symbol then add you second picklist api name
Save it
Activate the workflow
Enjoy 😊
If you want to write the Trigger, Refer the below link and change accordingly.
http://developer.force.com/cookbook/recipe/preventing-duplicate-records-from-saving