• Subject: Re: OPNQRYF question: how to build format without mapping each field
  • From: "Peter Dow" <pcdow@xxxxxxxxx>
  • Date: Tue, 30 Nov 1999 11:29:25 -0800

OPNQRYF question: how to build format without mapping each fieldIt sounds
like you are doing an OPNQRYF followed by a CPYFRMQRYF rather than an
OPNQRYF with a FORMAT parameter. In that case, the FMTOPT(*MAP) parameter
should do exactly what you want: "Fields with the same name in the open
query file and to-file record formats are copied, and fields in the to-file
that do not exist in the open query file format are set to the default value
specified on the DFT keyword for the data description specification (DDS) of
the to-file (or zero for numeric fields, blanks for character fields,
current date/time for date/time fields, or the null value for null-capable
fields)."

If some of the 10 fields in the input file do *not* exist in the output
file, then you will also have to use *DROP, i.e. FMTOPT(*MAP *DROP).

hth
Peter Dow
Dow Software Services, Inc.
909 425-0194 voice
909 425-0196 fax

+---
| 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:
david@midrange.com
+---


__________________________________________________
Do You Yahoo!?
Thousands of Stores.  Millions of Products.  All in one place.
Yahoo! Shopping: http://shopping.yahoo.com

+---
| 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: david@midrange.com
+---

This thread ...

Replies:

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

This mailing list archive is Copyright 1997-2019 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].