This topic is locked

Prevent Duplicate Records

4/27/2009 3:30:51 PM
PHPRunner General questions
J
jkeagle13 author

Hello,
I am looking for a way to avoid allowing the user enter duplicate records.
When they go to add a record they are forced to select an individual from a drop-down populated with a lookup. I would like some way to have it prevent them from adding the record. Perhaps as soon as they select the individual for whom it would be a duplication it could come up with a message saying "Record already exists. Please edit existing record."
I would probably use two separate criteria and if both already exist I would like them to be informed of the duplication and stopped in their tracks!
Thank you,

Joseph Irvine

Sergey Kornilov admin 4/27/2009

I would suggest to use BeforeAdd event where you can check if similar record exists. Sample action "Check if record exists" can point you in the right direction.

K
KevinMillican 4/28/2009

Hello,

I am looking for a way to avoid allowing the user enter duplicate records.
When they go to add a record they are forced to select an individual from a drop-down populated with a lookup. I would like some way to have it prevent them from adding the record. Perhaps as soon as they select the individual for whom it would be a duplication it could come up with a message saying "Record already exists. Please edit existing record."
I would probably use two separate criteria and if both already exist I would like them to be informed of the duplication and stopped in their tracks!
Thank you,

Joseph Irvine


You could also do this by adding an index to the appropriate table on the individual field and second criteria and making it unique.

J
jkeagle13 author 4/28/2009

Hello,
Is there anyway to do an event on dropdown menu selection change? My fear of onBeforeAdd is that they may spend a great deal of time filling out the form only to then realize it was for naught when they get an error message.
Thanks,

Joseph

J
Jane 4/29/2009

Joseph,
unfortunately no.