Get a first look at what's coming. The Developer Passport Australia Release Preview kicks off March 12. Dive in! 

Auto populate a text field

servicenow14710
Tera Expert

Hello developers, Can anyone share the logic,  i need to auto populate a text field once if any user registers/submit an order(catalog form) for the first time. If another user registers then the auto populated number should be incremented by 1. Any help is appreciated . Thanks!

6 REPLIES 6

@SunilKumar_P : Hi sunil, this is for particular catlaog item. The field which is getting incremented is a text field. Thanks for your reply!

vermaamit16
Kilo Patron

Hi @servicenow14710 

 

Below could be an approach :

 

1. Query the RITM table to check if any RITM already exists for the particular catalog item. If yes, then a user has already requested the catalog item previously. Take a count of the RITMs for the item and increment it by 1 to get the auto populated number. If no RITM exists, it is the first submission so the text field could be updated to have value as 1.

 

Thanks & Regards

Amit Verma

Thanks and Regards
Amit Verma