JotForm is a free online form builder which helps you create online forms without writing a single line of code. No sign-up required.
We believe that if one user has a question, there could be more users who may have the same question. This is why many of our support forum threads are public and available to be searched and viewed. If you’d like help immediately, feel free to search for a similar question, or submit your question or concern.
What you could do for your requested database return is use our Autocomplete Widget which allows you to enter in specific information in advance such as a code and have a name next to it. You could even go so far as to combine it with conditional logic if you wanted to do other things.
However, if you meant you want the user to enter in their own information, generate a code, then be able to search it later then no that would not work as the form is meant to collect data and not function as an administrative type system.
To do something like that you would need to send the submission data into an external database with php and pull it back into one of the fields using some custom programming outside of jotform with the form's source code.