Verify an existing record

17 Nov '16, 02:29 PM
3,828 Views
No Forum Badges

Hello, how I can verify before a registration if an attribute (email for example) of the form is also existing on database ?

Thanks

 
x 0
Follow
Answer Answer at this question and get points!
Forum Starter - Level 3

There are different ways to obtain what you need, depending of the expected user experience :

- attaching a "not in collection" validation rule to the form field, checking  if the value inserted in the field already exists in the "email" attribute of  the entity "users". 

- using an "on-change" ajax event attached to the form field that activates a selector unit retreiving existing record of the "users" entity  with the same value for the attribute "email", disabling the confirm link using a conditional activation expression. 

- implement an operation chain executing a selector unit before the create unit, if the value returned by the selector  is not null means that the inserted value already exist in database and you can skip the create step.

The first and third approach blocks the operation when the customer press the confirm button of the registration form, while the second react  immediately at every change of the form field value.

 

Roberto

   
x 3
No Forum Badges

Thanks! I try it Grazie

 
x 0
Answer at this question and get points!