Custom Error Message According Unique Fields

  • 0
  • 2
  • Question
  • Updated 2 years ago
  • Answered
I have a table called "Clients"
In this table I have a formula field called "Validation ID" which concatenates a client's first name, last name, and phone number into a single string.
Validation ID is also a unique field to prevent duplicate Client entries into the system.
When I try to save a duplicate client record a Quickbase message pops up saying 

"Fields which are marked unique must contain unique values for all the records. You have entered a duplicate value for the unique field "Validation ID" Please check your data and try again.
(The client was not saved)
"

Is there a way to modify/customize this message?

I would like for it to say something like "This Client Already Exists"





Photo of Dan Park

Dan Park

  • 450 Points 250 badge 2x thumb

Posted 2 years ago

  • 0
  • 2
Photo of QuickBaseCoach App Dev./Training

QuickBaseCoach App Dev./Training, Champion

  • 62,994 Points 50k badge 2x thumb
No problem. Sort of. The one thing you csn control is your field name. So experiment with a longer user friendly field name such as [This client already exists]
Photo of Dan Park

Dan Park

  • 450 Points 250 badge 2x thumb
My renaming the field the new message that would come up is... 

"Fields which are marked unique must contain unique values for all the records. You have entered a duplicate value for the unique field "This Client Already Exists" Please check your data and try again.
(The client was not saved)
"?
(Edited)
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 29,924 Points 20k badge 2x thumb
Using the IOL technique you can modify the message to suit your needs (but I don't think this is a great idea). See screenshot of manually applying the following script:

Pastie Database

https://haversineconsulting.quickbase.com/db/bgcwm2m4g?a=dr&rid=569

(Edited)
Photo of Dan Park

Dan Park

  • 450 Points 250 badge 2x thumb
Thanks. Why do you not think its a good idea?
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 29,924 Points 20k badge 2x thumb
It works but it is a bit invasive of QuickBase's authored page (I am modifying their standard error message after the fact).

Also, there might be other unique fields that should generate the same error message or other error messages associated with the same form submission and these possibilities would have to be explored.
(Edited)