qr86_26~2.txt
TXT text file 5 KB Posted
- Attached to
- FoxPro Migration - Open
- Solicitation number
- BD-27-1003-EOAS-EOAS-135643
- Issued by
- Suffolk County, Massachusetts
About this file
This file is a Visual Foxpro program (QR86_26.PRG) designed to track capital expenditure movement by day for Fiscal Year 2026 for an unspecified state or local government entity. The program analyzes budget data across four hierarchical levels—application group, management planning center (MPC), department, and activity number—to monitor how capital allocations are being utilized and to flag instances where expenditures exceed authorized budget limits. The program creates two output tables that consolidate budget information by acceptance date and organizational structure, calculates year-to-date figures at each hierarchical level, and identifies budget overages through flag markers. The program processes line-item transactions from a source database, applying debit or credit adjustments based on transaction type, and aggregates these movements across the organizational hierarchy to provide comprehensive budget variance analysis.
The program generates two deliverable datasets: table QR86_26A tracks daily capital movement with year-to-date accumulations by date and organizational unit, while table QR86_26B provides summary-level budget analysis including encumbered, expended, and unexpended amounts. The program identifies records with no budget allocation and flags any instances where expenditures at any organizational level exceed the established budget authority. Output files are exported in both DBF (dBASE) and CSV formats for distribution and analysis. The program includes reconciliation logic that cross-references budget records against a comprehensive capital budget table (QRCAP1) to identify missing budget allocations and ensure complete account coverage, supporting the entity's budget control and financial monitoring objectives for the fiscal year.
Text of this file
* PROGRAM: QR86_26.PRG
* Look at cap movement by day for FY26
* Visual Foxpro version close all create table qr86_26a FREE (flag c(1), accept c(10), appgrp c(4), mpc c(4), dept c(3), actnum c(8), level n(1,0),;
ytd_lvl1 n(14,2), ytd_lvl2 n(14,2), ytd_lvl3 n(14,2), ytd_lvl4 n(14,2),;
level1 n(14,2), level2 n(14,2), level3 n(14,2), level4 n(14,2)) index on accept+appgrp+mpc+dept+actnum to x1 create table qr86_26b FREE (flag c(1), no_budget c(1), appgrp c(4), mpc c(4), dept c(3), actnum c(8), level n(1,0),;
level1 n(14,2), level2 n(14,2), level3 n(14,2), level4 n(14,2), encumber n(14,2), expended n(14,2), unexpended n(14,2)) index on appgrp+mpc+dept+actnum to x2 select e use x86_26 SCAN for lineamt<>0 if type('accept')='D' XX1=dtoc(accept,1) XACCEPT=left(XX1,4)+'-'+substr(XX1,5,2)+'-'+substr(XX1,7,2) else XACCEPT=left(accept,10) endif
XDATE=XACCEPT
XAMT=lineamt*iif(incdec=2,-1,1) XMD=left(mdnum,3) XACT=left(actnum,8) XLEVEL=level0 if .t.
select a if not seek(XDATE+e.app_grp+e.mpc+XMD+XACT) append blank replace accept with XDATE, appgrp with e.app_grp, mpc with e.mpc, dept with XMD, actnum with XACT endif replace level4 with level4+iif(XLEVEL=4,XAMT,0) if not seek(XDATE+e.app_grp+e.mpc+XMD+space(8)) append blank replace accept with XDATE, appgrp with e.app_grp, mpc with e.mpc, dept with XMD endif replace level3 with level3+iif(XLEVEL=3,XAMT,0), level4 with level4+iif(XLEVEL=4,XAMT,0) if not seek(XDATE+e.app_grp+e.mpc+space(11)) append blank replace accept with XDATE, appgrp with e.app_grp, mpc with e.mpc endif replace level2 with level2+iif(XLEVEL=2,XAMT,0), level3 with level3+iif(XLEVEL=3,XAMT,0),;
level4 with level4+iif(XLEVEL=4,XAMT,0) if not seek(XDATE+e.app_grp+space(15)) append blank replace accept with XDATE, appgrp with e.app_grp endif replace level1 with level1+iif(XLEVEL=1,XAMT,0), level2 with level2+iif(XLEVEL=2,XAMT,0),;
level3 with level3+iif(XLEVEL=3,XAMT,0), level4 with level4+iif(XLEVEL=4,XAMT,0) select e endif if .t.
select b if not seek(e.app_grp+e.mpc+XMD+XACT) append blank replace appgrp with e.app_grp, mpc with e.mpc, dept with XMD, actnum with XACT endif replace level4 with level4+iif(XLEVEL=4,XAMT,0) if not seek(e.app_grp+e.mpc+XMD+space(8)) append blank replace appgrp with e.app_grp, mpc with e.mpc, dept with XMD endif replace level3 with level3+iif(XLEVEL=3,XAMT,0), level4 with level4+iif(XLEVEL=4,XAMT,0) if not seek(e.app_grp+e.mpc+space(11)) append blank replace appgrp with e.app_grp, mpc with e.mpc endif replace level2 with level2+iif(XLEVEL=2,XAMT,0), level3 with level3+iif(XLEVEL=3,XAMT,0),;
level4 with level4+iif(XLEVEL=4,XAMT,0) if not seek(e.app_grp+space(15)) append blank replace appgrp with e.app_grp endif replace level1 with level1+iif(XLEVEL=1,XAMT,0), level2 with level2+iif(XLEVEL=2,XAMT,0),;
level3 with level3+iif(XLEVEL=3,XAMT,0), level4 with level4+iif(XLEVEL=4,XAMT,0) select e endif
ENDSCAN
select a replace level with 1 for not empty(appgrp) replace level with 2 for not empty(mpc) replace level with 3 for not empty(dept) replace level with 4 for not empty(actnum)
SCAN
XACT=actnum XMD=dept XMPC=mpc XGRP=appgrp XDATE=accept XLVL1=level1 XLVL2=level2 XLVL3=level3 XLVL4=level4 xx=recno() replace ytd_lvl1 with ytd_lvl1+XLVL1, ytd_lvl2 with ytd_lvl2+XLVL2, ytd_lvl3 with ytd_lvl3+XLVL3,;
ytd_lvl4 with ytd_lvl4+XLVL4 for actnum=XACT and dept=XMD and mpc=XMPC and appgrp=XGRP and accept>=XDATE goto xx
ENDSCAN
replace flag with 'X' for level=1 and ytd_lvl1<>ytd_lvl2 replace flag with 'X' for level=2 and (ytd_lvl2<>ytd_lvl3 and ytd_lvl3<>0) copy to k:\dbf\qr86_26a TYPE fox2x IF .t.
FILE1='qr86_26a' DO p:\vfox\MAKE_CSV endif select b replace level with 1 for not empty(appgrp) replace level with 2 for not empty(mpc) replace level with 3 for not empty(dept) replace level with 4 for not empty(actnum) replace flag with 'X' for level=1 and level1<>level2 replace flag with 'X' for level=2 and (level2<>level3 and level3<>0) select c use qrcap1
SCAN
select b
XLEVEL=1
locate for level=1 and appgrp=c.apprgrp if not found() append blank replace level with 1, appgrp with c.apprgrp, no_budget with 'X' endif
XLEVEL=2
locate for level=2 and appgrp=c.apprgrp and mpc=c.mpc if not found() append blank replace level with 2, appgrp with c.apprgrp, mpc with c.mpc, no_budget with 'X' endif
XLEVEL=3
locate for level=3 and appgrp=c.apprgrp and mpc=c.mpc and dept=c.mdnum if not found() append blank replace level with 3, appgrp with c.apprgrp, mpc with c.mpc, dept with c.mdnum, no_budget with 'X' endif select c
ENDSCAN
select b replace unexpended with level1-expended for level=1 replace unexpended with level2-expended for level=2 replace unexpended with level3-expended for level=3 replace unexpended with level4-expended for level=4 copy to k:\dbf\qr86_26b TYPE fox2x
Other files
| File | Type | Posted |
|---|---|---|
| Copy of x86_26~3.xlsx | XLSX spreadsheet | |
| EOANF RFQ - FoxPro Module Replacement - Open.docx | DOCX document | |
| Copy of Visual FoxPro Module Inventory~2.xlsx | XLSX spreadsheet | |
| ITS86 SOW - Fixed Price~3.docx | DOCX document | |
| Copy of QRCAP1~3.xlsx | XLSX spreadsheet |
On GovTribe
Work with this file
- Download the original file
- Contacts named in this file
- Similar government files
- Ask GovTribe AI about this file
File details come from the government source that posted it. Updated .