Print Page as PDF
IAs for VAFCTFU utilities ICR (2988)

IAs for VAFCTFU utilities    ICR (2988)

Name Value
NUMBER 2988
IA # 2988
DATE CREATED 1999/11/19
CUSTODIAL PACKAGE REGISTRATION
CUSTODIAL ISC Albany
USAGE Controlled Subscription
TYPE Routine
DBIC APPROVAL STATUS APPROVED
ROUTINE VAFCTFU
NAME IAs for VAFCTFU utilities
GENERAL DESCRIPTION
MPI Vista is requesting a DBIA with Registration to
call DELALLTF^VAFCTFU to remove all associated treating facilities for a
patient who's ICN has been inactivated.

DELALLTF(PAT)   ;Entry point to delete all Treating Facilities for a single
patient.
;INPUT  PAT - The patient's ICN
;OUTPUT 0 (zero) - If no errors
;       1^error description if an error

MPI/PD is requesting an IA with Registration to call FILE^VAFCTFU.  This
subroutine is used to file data into the TREATING FACILITY LIST (TFL -
#391.91) file (via the ADT/HL7 PIVOT file) under certain conditions.

FILE(PDFN,FSTRG,TICN)   ;this module files the individual entry
input: PDFN - patient dfn
FSTRG- string, three pieces delimited by an '^'
1st piece: treating facility
2nd piece: last treatment date for the patient
3rd piece: Event Reason (ADT/HL7 EVENT REASON
#391.72) file
TICN - boolean flag, do not update the TFL file
(via the PIVOT file) if TICN equals one.

MPI/PD needs to expand this DBIA to include a call to DELETE^VAFCTFU.  This
call is necessary to address the issue of duplicate treating facilities
assigned to a patient, therefore the variable being passed is the internal
entry number in TREATING FACILITY LIST FILE (#391.91) not the IEN for a site
that the other calls are using.

DELETE(TFIEN)   ;the actual deletion code
;
K DIK,DA
S DIK="^DGCN(391.91,"
S DA=TFIEN
D ^DIK K DIK,DA
Q
STATUS Active
KEYWORDS
  • FILE
  • DELALLTF
  • DELETE
DURATION Till Otherwise Agreed
ID VAFCTFU
COMPONENT/ENTRY POINT
COMPONENT/ENTRY POINT COMPONENT DESCRIPTION VARIABLES
DELALLTF
$$DELALLTF(PAT)   ;Entry point to delete all Treating
Facilities for a single patient.
;INPUT  PAT - The patient's ICN
;OUTPUT 0 (zero) - If no errors
;       1^error description if an error
VARIABLES TYPE VARIABLES DESCRIPTION
PAT Input
PAT = ICN for the given patient
RETURNS Output
This function returns either:

0 (zero) - If no errors
1^error description if an error
FILE
This subroutine is used to file data into the
TREATING FACILITY LIST (TFL - #391.91) file (via the ADT/HL7 PIVOT file) under
certain conditions.
VARIABLES TYPE VARIABLES DESCRIPTION
PDFN Input
The internal entry number of the patient in the
PATIENT (#2) file.
FSTRG Input
This variable is three piece string delimited by an
'^'

1st piece: treating facility 2nd piece: last treatment date for the patient
3rd piece: Event Reason (ADT/HL7 EVENT REASON #391.72) file
TICN Input
This variable acts as a boolean flag.  Do not update
the TFL file (via the PIVOT file) if TICN equals one.
$$DELETETF(PAT,INST)
If the legacy site is on the treating facility list
for a patient that it should be deleted.
VARIABLES TYPE VARIABLES DESCRIPTION
PAT Input
ICN of the patient
INST Input
IEN of the institution to be deleted
$$DELETETF Output
0 (zero) - If no errors 1^error description if there
was a problem
DELETE(TFIEN)
Used to delete specific entries in the TREATING
FACILITY LIST FILE (#391.91) when identification of the site is not enough.
VARIABLES TYPE VARIABLES DESCRIPTION
TFIEN Input
Internal entry number of a specific record in the
TREATING FACILITY LIST FILE (#391.91).
SUBSCRIBING PACKAGE
SUBSCRIBING PACKAGE ISC
MASTER PATIENT INDEX VISTA Oakland
CLINICAL INFO RESOURCE NETWORK Birmingham
CORBA SERVICES
MAIL MESSAGE 30466266