It is not expected that users will change this table as the settings have system wide usage.
At this time this is a brief description only.
There will be installed a complete set of rules for your selection of Feeder systems, do not play with them unless you understand deeply. The rules are not specific to your site unless the feeder is specific to your site. Some requesting Feeders may use the "ANY" set of generic rules.
ID |
The Automatic record ID - do not alter |
Feeder System |
The Episode Requesting Feeder System, the one asking for an episode, not the one creating it Please note this is actually the Module code, not the campus specific Feeder system code. |
Type |
The Episode type rules for that requesting feeder, not the type it is specifically requesting |
Priority |
The order in which the table of possible matches will be sorted and from which the first, i.e. the lowest priority matching episode to the parameters passed - phew. Within similar priority levels, possible matches are further sorted by the Absolute value of the mid-point of the episode and the date and time of service, so the best match will apply. |
Chk Times |
For this rule will we look at times of service as well as times of Admit and Discharge. Of course this should only be selected if the Feeder System can provide a meaningful time of service (is Label printing time for a drug a meaningful time?), and of course it should only be checked if the episode type we are asking for can provide meaningful times of beginning and ending, e.g. OP Appointment time is not meaningful in this context, whereas admit date and time and discharge date and time should be. |
+ Offset - Offset |
For any requesting feeder - sometimes - after looking for an exact match, we may need to widen the scope, for OP we always use a +14 -14. These rules can be used with the Priority field to cascade an ever widening series of rules for various feeders so that an exact match on date and time in IP, an exact date and time in AE, then IP +1 / -1 day etc. Trendcare where the "Date of Shift" can be either before of after actual date of admission or discharge (never sure which it is) has a wide aperture |
"Include Canc" elled Episode |
In some feeders e.g. Radiology, it is wise for OP to include cancelled episodes for matching. "Have an Xray the week before I see you next time Mr's Smith, in three months time", in three months Mr's Smith has the Xray and is immediately admitted for removal of surgeons golf clubs (I wondered where they got to), appointment is cancelled as patient is now IP! |
RE COPY Button |
if you delete rows, the re-copy will allow rows from the Module version of rules or "ANY" if there is no set of Module rules available. This will occur any time the form is opened and ensure that Linking rules are available for all your Modules and feeders. |
More About ANY |
ANY is a template if you like, rules are cascade copied from ANY to a new module, then from a Module to a satellite site feeder. Rules that have been copied from ANY show that in the Notes, Rules copied from the Module version carry the module Notes |
The Bottom Line |
This shows how to call the Episode Function. When using it in an SQL statement or on Crystal, reference the fields rather than the quoted parameters. e.g. UR not '123456' and Campus_TLA not 'TSV'. The parameter for the feeder can be either feeder_code, module_code, creating_feeder or similar, or even hard coded in the SQL to use the rules you want to use. (don't put the = 'episode_number' bit in). The parameters are as follows |
dbo.fnEPID(Service_date,UR,feeder rules,Campus_TLA) |
|
Service Date |
Depending on the file and the data supplied this could be the field Service_date, or Request_Date |
UR |
Generally UR or tablename.UR |
Feeder Rules |
Either link to the Feeder_System_code, Creating_ feeder, Module, or Module_code depending on the table, or select a string in single quotes that reflects the rules you want to use for this query |
Campus_TLA |
Note the CAMPUS will determine which patients to look at, very important to reference this correctly |
dbo.fnEPID2(Service_date,UR,feeder rules,Campus_TLA,defEP) |
|
This version allows the use of a default unlinked episode instead of the one assigned by the function which is generally UR.feeder.dateofservice. You can code a concatenated string |
See the Episode Matching Test page for information on testing these rules