Set unique session number for a form

kevinv

Registered User.
Local time
Today, 05:18
Joined
Mar 31, 2009
Messages
11
I would like to create a form where a unique number is assigned to this form once it is opened. This continous form will include a number of entries one below the other. On closing the form I would like to update the table with the following fields, Date, Invoice Number and the session number originally given to the form. Reason behind the session number is, so that if I would require to know which invoices where inputted in session number 1 I would need to query that field and the result will display all the invoices which are related to that session number.

Thank you.
 
Is this going to be used in a multi user environment?

You need to decide if you want to grab the session number before the user starts entering invoices or after they have entered their last invoice.

If you choose before and it's multi user you could have issues with more than one person grabbing the same next session number.

David
 
Hi David, Thank you very much for your reply.

Preferrably will be used in a multi-tasking environment however there might be the following working scenarios

I would have only one person registering invoices at a time therefore would be better that on loading the form to register these invoices a session number is given that time.

In the mean time I may have users querying for an invoice to check the status so lets say the storekeeper is recording the invoices being returned to him and at the same time I have someone else querying a particular invoice which might have been retunrned weeks ago.

Thanks
 
So what you want is to record batch numbers for invoice processing? correct?

Therefore on the onload of the form get the max batch/session number for the invoice logging table and add one to it.

Then each time the user processes an invoice store this value into the invoice logging table. Lets say they have 20 invoices in their in-tray they then open the invoice processing form, at which point it gets the next batch number, say 21, then the users processes the first 10 and as such 21 is assigned to each batch process number in the table. They then close the form and go away and get some lunch, when they return they open the form again, and as before it get the next available batch number (22) they then process the reamining 10 invoices, all of which is assigned 22 to the batch/session number. Even though the date is the same you will be able to identify that they were processed in two sessions.

Are you recording who processed them as well as the time they were processed? This can come in handy for traceability.

David
 
Yes the idea is exactly how you understood.

Just for you to understand better the table where i'm going to store the records would look something like this;

DATE INVOICE NUMBER STORES SESSION NUMBER
01/04/09 123456 DRY 21
01/04/09 123457 DRY 21
01/04/09 123460 DRY 21
01/04/09 123470 DRY 21

With regards to tracebility my warehouse is divided in two locations being dry food and Frozen & Chilled products. Both have their respective storekeeper and two different form to use, one for dry and one for frozen. But they use the same computer so only one person can register invoices at a time. They just use their respective form. All records are stored in one table then I extract the information I need by Excel. Using the session number I would be able to extract the invoices which were recorded under session 21 onto an excel sheet.

Kevin
 

Users who are viewing this thread

Back
Top Bottom