Well, I´ll try to explain what I am doing.
The users of the system creates jobs. (The users are consultants and when they have helped our customers they report into the system what they have done and that is a job).
Then we print out a report as basis for the invoicing with all the jobs that is marked as "finnished".
When we do this printout the system ask if it´s OK (yes, in Swedish, sorry) and if it is the jobs on the report are updated and flagged as "printed" and here is the question:
If someone enters a new job between the printout and the OK-click that job will also be flagged as "printed" but will offcourse not actually be printed since the printout occured before. Thus we will not send an invoice to the customer (horrible thought..) and eventually become poor people 🙂
See, the problem?
So I think of three ways to solve it: either
1.) Lock the system so new jobs cannot be entered during that time
2.) Update the records before the printout and then roll it back if the printout wasn´t ok
3.) Somehow check if the printout process(es) is started but not finnished and make sure new records are not flagged as "printed"
Hope this makes thing a bit clearer!
/Rem