G
Guest
I am very new to this and need some help..
I have set-up a table for assigning, scheduling, and tracking patient accounts for insurance follow-up. The source for this data comes from an external system. Every night, the external system produces a file of new patient encounters that we upload into the database. Each patient has a unique account number and each account number may have one or more encounter dates. In the table the records appear as follows
Patient Number, Patient Name, Encounter Date, User Assigned, etc. etc
100005433, John Smith, 02/05/2004, USER
100005433, John Smith, 02/12/2004, USER
100005433, John Smith, 02/28/2004, USER
100008702, Fred Jones, 02/07/2004, USER
100008702, Fred Jones, 02/10/2004, USER
What I need to do is when a new record is pulled into the database, I have to find a way to assign the record to one of a group of six users. The catch is that this cannot be at random. When a record comes in for a new patient encounter but that patient's account number already exists in our database, then the new record must be assigned to the same user that already has the other encounters for that same account number. If the new record is for an account number that we do not already have in the database, then we have to assign to any of the users. But... we don't want to just deal these new account numbers out at random. We want to be able to assign new records to the users who have the fewest records already assigned to them. The plan being to try to keep all six users with about the same number of records to work. Worse yet, existing records do finally get worked to completion and they become flagged as "inactive" in a record status field. The "inactive" records are not to be counted when trying to balance the workload
SO... is this something that can be done realistically? I imagine that setting this up will be rather complicated. Any suggestions on how to accomplish this task
Thanks
Davi
I have set-up a table for assigning, scheduling, and tracking patient accounts for insurance follow-up. The source for this data comes from an external system. Every night, the external system produces a file of new patient encounters that we upload into the database. Each patient has a unique account number and each account number may have one or more encounter dates. In the table the records appear as follows
Patient Number, Patient Name, Encounter Date, User Assigned, etc. etc
100005433, John Smith, 02/05/2004, USER
100005433, John Smith, 02/12/2004, USER
100005433, John Smith, 02/28/2004, USER
100008702, Fred Jones, 02/07/2004, USER
100008702, Fred Jones, 02/10/2004, USER
What I need to do is when a new record is pulled into the database, I have to find a way to assign the record to one of a group of six users. The catch is that this cannot be at random. When a record comes in for a new patient encounter but that patient's account number already exists in our database, then the new record must be assigned to the same user that already has the other encounters for that same account number. If the new record is for an account number that we do not already have in the database, then we have to assign to any of the users. But... we don't want to just deal these new account numbers out at random. We want to be able to assign new records to the users who have the fewest records already assigned to them. The plan being to try to keep all six users with about the same number of records to work. Worse yet, existing records do finally get worked to completion and they become flagged as "inactive" in a record status field. The "inactive" records are not to be counted when trying to balance the workload
SO... is this something that can be done realistically? I imagine that setting this up will be rather complicated. Any suggestions on how to accomplish this task
Thanks
Davi