Hi Chuck - >Date: Thu, 14 Oct 1999 14:59:42 +0100 >From: Chuck Lewis <email@example.com> >Subject: PF File Definition questions... >Is there something I'm missing when it comes to NOT having the "most >common" field(s) in a PF defined in the PF a key field(s) ? My feeling is that files that require uniqueness should have the physical file keyed with the unique field(s) and UNIQUE specified. All of the logicals should have those field(s) as the last key field(s) to ensure a consistence sequence regardless of the relative record number. In other words, all of the logicals will actually end up being unique keyed as well, but don't actually specify UNIQUE. It isn't needed because the physical is enforcing uniqueness, and it would hurt performance as well. History type files and other files that do not require uniqueness I usually create with an unkeyed physical. I try to create the logicals with sufficient key fields to insure a consistent order, though that may not always be possible at an absolute level (if it was, there would be uniqueness, even if not enforced). So my usual practice is: 1. only physical files are ever keyed UNIQUE. 2. physical files are either keyed UNIQUE or not keyed. 3. if there should be uniqueness, do enforce it with a uniquely keyed physical. 4. as much as possible, create logicals that will read in the same order regardless of relative record numbers. (With a uniquely keyed physical, this is always possible.) Everything else is just application of those principles. Ken Southern Wine and Spirits of Nevada, Inc. +--- | This is the Midrange System Mailing List! | To submit a new message, send your mail to MIDRANGE-L@midrange.com. | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com. | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: firstname.lastname@example.org +---
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.