Home   Package List   Routine Alphabetical List   Global Alphabetical List   FileMan Files List   FileMan Sub-Files List   Package Component Lists   Package-Namespace Mapping  
Routine: IBCORC

IBCORC.m

Go to the documentation of this file.
  1. IBCORC ;ALB/CPM - RANK INSURANCE CARRIERS ; 30-JUN-93
  1. ;;Version 2.0 ; INTEGRATED BILLING ;**29**; 21-MAR-94
  1. ;
  1. EN ; Entry point to generate ranking of insurance carriers by amount billed
  1. ;
  1. W !!?6,"This report will generate a list of insurance carriers ranked by"
  1. W !?6,"the total amount billed. Please note that you may no longer opt"
  1. W !?6,"to transmit this report to the MCCR Program Office in VACO using"
  1. W !?6,"this option."
  1. W !!?6,"You must select a date range in which bills to be used in the"
  1. W !?6,"totals will be selected."
  1. ;
  1. START W ! S DIR(0)="DA^2860101:NOW:EX",DIR("A")="Enter Start Date on Bill Search: ",DIR("?")="^D HLPD1^IBCORC"
  1. D ^DIR K DIR S IBABEG=+Y G:'Y ENQ
  1. ;
  1. END W ! S DIR(0)="DA^"_+Y_":NOW:EX",DIR("A")="Enter End Date on Bill Search: ",DIR("B")=$$DAT2^IBOUTL(DT),DIR("?")="^D HLPD2^IBCORC"
  1. D ^DIR K DIR S IBAEND=+Y G:'Y ENQ
  1. ;
  1. NUM W ! S DIR("A")="Enter number of insurance carriers to rank: ",DIR(0)="NA^1:1000:0",DIR("B")=30,DIR("?")="^D HLPN^IBCORC"
  1. D ^DIR K DIR S IBNR=+Y G:'Y ENQ
  1. ;
  1. ; Allow report transmittal if running in Production.
  1. S IBFLG=0 ; G:'$$PROD DEVICE
  1. ;
  1. ;W ! S DIR(0)="Y",DIR("B")="NO",DIR("A")="Would you like this report sent to the MCCR Program Office",DIR("?")="^D HLPCO^IBCORC"
  1. ;D ^DIR K DIR S IBFLG=+Y I $D(DIRUT)!($D(DUOUT)) G ENQ
  1. ;
  1. DEVICE ; Select device for queueing/printing report
  1. S %ZIS="QM" D ^%ZIS G:POP ENQ
  1. I $D(IO("Q")) D G ENQ
  1. .S ZTRTN="DQ^IBCORC1",ZTDESC="RANK INSURANCE CARRIERS"
  1. .F I="IBABEG","IBAEND","IBFLG","IBNR" S ZTSAVE(I)=""
  1. .D ^%ZTLOAD K IO("Q")
  1. .W !!,$S($D(ZTSK):"This job has been queued as task #"_ZTSK_".",1:"Unable to queue this job.")
  1. .K ZTSK
  1. U IO
  1. D DQ^IBCORC1
  1. ;
  1. ENQ ; Cleanup
  1. K I,IBABEG,IBAEND,IBFLG,IBNR
  1. Q
  1. ;
  1. ;
  1. PROD() ; Is this the production account? Output: 1 - YES, 0 - NO
  1. N X S X=$G(^XMB("NETNAME"))
  1. Q $L(X,".")=3!($L(X,".")=4&(X[".MED."))
  1. ;
  1. HLPD1 ; Help for Start date.
  1. W !!,"This report uses the date the bill was first printed to determine if the"
  1. W !,"bill should be included in the accumulative total."
  1. W !!,"Please enter the lower date range for the first printed date, which"
  1. W !,"should be a past date on or after 10/1/86, or '^' to exit."
  1. Q
  1. ;
  1. HLPD2 ; Help for End date.
  1. W !!,"This report uses the date the bill was first printed to determine if the"
  1. W !,"bill should be included in the accumulative total."
  1. W !!,"Please enter the upper date range for the first printed date, which"
  1. W !,"should be a past date on or after ",$$DAT1^IBOUTL(IBABEG),", or '^' to exit."
  1. Q
  1. ;
  1. HLPN ; Help for number of carriers to rank.
  1. W !!,"This report will rank any number of insurance carriers (from 1 to 1000)"
  1. W !,"for the total amount billed within a date range."
  1. W !!,"Please enter a number between 1 and 1000, or '^' to exit."
  1. Q
  1. HLPCO ; Help for sending report to Central Office.
  1. W !!,"After the new fiscal year begins, this report should be generated for the"
  1. W !,"previous fiscal year and transmitted to the MCCR Program Office. The data"
  1. W !,"will be compiled nationally to determine which insurance carriers are the"
  1. W !,"largest customers of VA. The compiled data will assist the Program Office"
  1. W !,"in planning for future electronic billing systems."
  1. W !!,"Even if you are planning to transmit a report to the Program Office, you"
  1. W !,"should run this report once without transmitting to check the results."
  1. W !,"You may then re-run the report and transmit it centrally."
  1. Q