Moonsoft Software Solutions

What code I should use to Custom Validation in the column to check if the entered data is already exist in the database table or not?

Started 24 Mar 2022 · 2 replies

  1. aliwari
    Hi LMS Team,

    Would you please tell me how can I configure a form column to check the user entered data before filling up the whole form and save it, I mean what code I should add in the Fields/Columns/Custom Validation to check if the entered data during filling the form is already exist in the database table or not? and if it's exist, the column should show a sign during filling time such as turning red or something like that.
    I did configured one column as unique, so user can't entered the same data on the same filed. but the user will not know about it until he/she save it.


    Regards



    Ali
  2. Moonsoft support
    Hi,
    that function would require to perform a validation at the server side, querying the database and going back to the form, so this is a task you can't code using javascript at the front-end with the custom validation parameter. For that kind of operation you would need to ask a developer to build a server-side method able to do that, and also code the javascript part at the 'custom validation' field, calling the server and handling the response.

    Best regards
  3. aliwari
    Hi,

    Oh I see

    Thanks you


    Ali

Still stuck?

Customers with an active license can open a support ticket.

Log in to open a ticket