Hi guys,
As I have created an indexes to avoid a duplicate data entry in database. Once I click on save button if there is an duplicate values it gives an error but it is not user understandable.so how to make that error user understandable like display error message "Duplicate data entry" . See the attachment
Attach .oml if possible
Hi Rohan,
Hope you are doing well.
You need to handle DatabaseException and send Feedback_Message (with Message Text like "Duplicate data" and Message Type = Entities.MessageType.Error) in the save screen action (or any other screen action that you are using to save those data in the database).
Request you to please check the attached screenshot and hope it will help you.
Many Thanks,
SKG
Hi,
You can add an exception handler to your save action to catch the database exception and provide a user friendly feedback using a feedback message in the exception handler flow.
Regards,
Daniel
But how to specify database INDEX type exception, because there are lots of possible database exceptions. Is there a way to catch specifically Database Index Exceptions?
No. I believe he wants to return a generic message and also human readable.