|
Physical file is SLHSTDTP. It gets cleared on Jan 1st each year and then accumulates invoicied detail throughout the year. At the end of March, the record count was approx 2,900,000. I am only showing relevant lines from the source member. A * Description: Sales History Detail Physical File A R SLSHDR TEXT('Sales History Record') -------------- 9 data records excluded ----------------------------------------- A WDATE L DATFMT(*MDY) DATSEP('/') A TEXT('Date Invoiced') -------------- 76 data records excluded --------------------------------------- Logical file is SLHSTDL9. Maintenance is *IMMED. All lines from the source member are shown. A* Description: Sales History Detail by Customer, Item, Date A R SLSHDR PFILE(SLHSTDTP) A K WCUST# A K WITEM A K WDATE RPG/LE program DRPURBLR uses the logical file to summarize the sales data by customer and item for a specific weekly period. This data is being written to a flat file that is sent to another company. -------------- 57 data records excluded --------------------------------------- FSLSHSTDL9 IF E K DISK -------------- 12 data records excluded --------------------------------------- D BgnDte S D DatFmt(*MDY) D EndDte S D DatFmt(*MDY) -------------- 106 data records excluded -------------------------------------- C *Entry Plist C Parm P#Vend 5 C Parm P#BegD 8 C Parm P#EndD 8 -------------- 5 data records excluded ----------------------------------------- C Move P#BegD BegDat 8 0 C Move P#EndD EndDat 8 0 C *ISO Move BegDat BgnDte C *ISO Move EndDat EndDte -------------- 2 data records excluded ----------------------------------------- C KLDL9 Klist C KFld CCUST# C KFld WITEM C KFld BgnDte C* C KLDL92 Klist C KFld CCUST# C KFld WITEM -------------- 136 data records excluded -------------------------------------- C KLDL9 SetLL SLHSTDL9 C KLDL92 ReadE SLHSTDL9 25 C DoW Not *IN25 -------------- 162 data records excluded -------------------------------------- C KLDL92 ReadE SLHSTDL9 25 C EndDo -------------- 150 data records excluded -------------------------------------- The problem is that all records for the Customer and Item are being read. The date key field on the KLDL9 key list is not positioning the logical at the correct place. It's like the date is being ignored. I can restrict the records being included by placing a logic statement inside the Do loop that checks for WDATE between the Beginning Date and Ending Date. Because of the size of the file, the performance is not acceptable and it will get worse as we progress into the year. Has anyone seen anything like this? Anybody have any ideas? I am on V3R2. Joe Teff QDS Bloomington, MN +--- | This is the Midrange System Mailing List! | To submit a new message, send your mail to MIDRANGE-L@midrange.com. | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.