× 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.



> Also, the RPG program's F-spec for this file shows the start position for
> this key as 1 (does it matter for alt. indexes?)

the key starting position does not matter. at execution it checks the file
at
open time and uses the key of the disk file. the reason some coders make the
start position 1 is if the alt index key is non-contiguous, the rpg compiler
edits the start position plus key length LE file length.

> The physical record is 320 bytes in length, but the logical record is
334...

the dspffd shows the key fields at end of file, and you will notice the key
field references a substring of a "real" field in the file, like F000001.
The real file on disk is only 320. It was ibm's way of showing the
definition
of the keys for this logical. Be careful in looking at this, K00001 is not
always
a key of the logical, but the key of the physical. Look for the "SST"
substring
fields after the end of the real record length.

btw - you can do sql selects on these 36 files by doing the same kind of
substring, although I never got packed fields to work in a SELECT.

hth
jim franz
----- Original Message -----
From: "Dan Bale" <dbale@samsa.com>
To: <rpg400-l@midrange.com>
Sent: Tuesday, April 30, 2002 1:59 PM
Subject: S/36-mode alt indexes


> Having to partially dissect a 9000-line RPG-II program and came across a
> file spec for a file that is an alternate index.  I'm really confused.
Does
> IBM do some blackbox stuff for alt. indexes?  I know that they are logical
> files.  The physical record is 320 bytes in length, but the logical record
> is 334 and a DSPFFD list puts the two key fields defined for the alternate
> index in 321-327 & 328-334.
>
> Also, the RPG program's F-spec for this file shows the start position for
> this key as 1 (does it matter for alt. indexes?)
>
> - Dan Bale
> (I am *NOT* "Dale"
> http://archive.midrange.com/midrange-l/200105/msg00281.html )
> SAMSA, Inc.
> 989-790-0507
> DBale@SAMSA.com <mailto:DBale@SAMSA.com>
>   Quiquid latine dictum sit altum viditur.
>   (Whatever is said in Latin seems profound.)
>
> _______________________________________________
> This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing list
> To post a message email: RPG400-L@midrange.com
> To subscribe, unsubscribe, or change list options,
> visit: http://lists.midrange.com/cgi-bin/listinfo/rpg400-l
> or email: RPG400-L-request@midrange.com
> Before posting, please take a moment to review the archives
> at http://archive.midrange.com/rpg400-l.
>
>




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

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.