× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Don,

<snip>
That sounds very interesting.  It sounds like I have something to chew on
and aspire to.  At present I can't imagine how to softcode a character
variable between 1 and 20 characters with only six indicators, never mind
the actual position of the field and associated headings.  The DBU utility
manages it for it's subfiles so I'm certain it can be done.
</snip>

It isn't that difficult - you just bank the indicators in blocks - 6 indicators allow 64 possible variations:

Below are two fields that occupy the same position in a subfile line. Thie first is a 1A, the second is a 2A. The indicator values for each are - 000001 & 000010. Obviously, the 3A field has 000011. These 6 indicators allow you to specify 64 different length fields. You simply save the bank into a hidden field on the subfile line. So, when you read the line (via readc) the hidden field will tell you which field was actually active on that line.

A N40N41N42
A N43N44 45  I@A01A         1A  B  9 19
A  47                                  DSPATR(HI)
A  48                                  DSPATR(RI)
A N48                                  DSPATR(UL)
A  48                                  DSPATR(PC)
A N40N41N42
A N43 44N45  I@A02A         2A  B  9 19
A  47                                  DSPATR(HI)
A  48                                  DSPATR(RI)
A N48                                  DSPATR(UL)
A  48                                  DSPATR(PC)

This isn't TOTAL position control. Our subfile fields form two columns down the screen. The subfiles take the form:

Country. . . . : GB                      Warehouse. . . : 5801    LEICESTER
Report Group . : WHS_REPORT Warehouse reports
Report Name. . : PRTCTNRPT2

Enter parameters required for this selection;
Warehouse. . . : ____                    Carrier Code . : __
Sameday ?. . . : _                       Box Type . . . : __
Furniture ?. . : _                       Date To. . . . :  3/12/2004
Time To. . . . : 23:59                   Non Assoc Ctns : _
Auto Scan. . . : _                       Remote Whse. . : ________
Customer Type. : ____                    Print Summary. : _

Every field below the "Enter parameters..." literal is a subfile field. Apologies if this doesn't post well -cunNpaste into Courier New to see it properly.

<snip>
Out of curiosity, do you also allow the values to be saved as named defaults
or by user?  We allow that so the users can define multiple version of
reports that be executed daily, weekly, or monthly.
</snip>

We define our reports by group. The screen is actually built from the command used to run the report. So you can group the reports anyway you wish. Users are then granted visibility of report groups. This allows us to hardcode certain parms - any hardcoded parms do not appear in the selection screen This allows some users visibility of certain areas, while other users have visibility over all areas. We also have a second file that controls the execution of the report. This file controls things such as whether the doc is spooled, whether the user can elect to print it into Excel or PDF and email it to a group of users.

Some reports are grouped to run daily, and run at 5:am. These are set with the previous date (again on a file) and run summaries for various managers. Their emailed spreadsheets are waiting in their inbox when they start in the morning.

Here is a copy of the command used to load the screen above:

CALL PRTCTNRPT PARM('!ILOC' '&CARR' '&SAME' '&BXTY' '&FURN' '&dtto' '&TMTO' '&ASSC' '&SCAN' '&RMTW'
' ' ' ' 'PD' ' ' '&CUTY' '&VAR(Y/N,DSO3395)')


Any parm beginning with "!" is mandatory (white on screen) and any parm beginning with "&" is optional. We have a set of pre-defined fields. So "CARR" is always a 2A carrier code and it's description is pre-determined. However, we can use &VAR or !VAR to specify any supported field. As you can see, above we have an optional Yes-No field. The description is contained in the attached message ID. The application knows that the only valid values for Y/N fields are Y or N! (Or O/N in France, J/N in Germany, S/N in Italy, etc...) The "date to" field &dtto defaults the current date. It is displayed in *EUR format because it's in lowercase. If it was &DTTO it would be in *ISO format!

Anyway, you get the idea. The selection screen simply substitutes the variables in the command with the data entered in the screen. The command is then executed (or submitted). You can specify a prompt program for each field within the command, but that's another story.

(the fun begins when you create a report group called "handy utilities" and then put in a report command such as ?WRKOUTQ. As the commands are simply executed - you can add handy options into the system on the fly.)

HTH

Cheers

Larry Ducie



As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.