I'm trying to build a form that will be accessed by many people, and will insert records into a PostgreSQL database. Now, I need to assign a sequential serial number to each record, but I have a problem with this: The form is ten rows of input. If someone enters all ten rows, I will need to do ten inserts, but have the same serial number assigned to each one.
Can anyone think of a way to store like a variable, the last serial number that was used, and add 1 to it each time someone submits the form?
Thanks for all your help 🙂