Number Sequencing

itnchans

Registered User.
Local time
Today, 00:35
Joined
Nov 29, 2007
Messages
11
Hi

I'm currenly involved in creating a database for a customer invloving project management and production management. When job are released into to production they are given a run number - order in which job is processed. For example

Job 1 will be run 1st
Job 2 will be run 2nd
Job 3 will be run 3rd
Job 4 will be run 4th
Job 5 will be run 5th
etc....

But if the mangement decide that a specific job (say No. 4) has priority and moved it to run sequence 2, the impact would be that job 2,3 run sequences would change to 3,4. so we get

Job 1 will be run 1st
Job 4 will be run 2nd
Job 2 will be run 3rd
Job 3 will be run 4th
Job 5 will be run 5th
etc....

or

Job 5 will be run 1st
Job 3 will be run 2nd
Job 4 will be run 3rd
Job 1 will be run 4th
Job 2 will be run 5th
etc....

I know how to get the last run sequence number (DMax + 1), so all new job are tagged to the end of the queue.

What I need help with code that will allow me move a job up and down the queue and to re-sequence the run order, depending where it is moved to, as in the example above.

Any help would be appreciated.
 
I think you require an extra field for sequencing. You can then use that field to sort in a query.
 

Users who are viewing this thread

Back
Top Bottom