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


  • Subject: OPNQRYF - duplicate field name error
  • From: "David Prowak" <dprowak@xxxxxxxxxxxxxxxxx>
  • Date: Wed, 14 Jun 2000 15:13:28 -0700

Hi,
 
I'm using an Opnqryf to join 2 files and select some recs from the joined file.
 
The problem is that the field that I'm joining on has the same name in each file, so that I'm
getting a "field TICKET found in more than one record format" error.
 
I've tried renaming the field using MAPFLD, but I still get the same error.
How can I fix this?
 
Here's the code using the MAPFLD:
                                                          
 OPNQRYF    FILE((TRPTOPAY) (TRPMASTR)) FORMAT(TRPTOPAY) +
              QRYSLT('STATUS *EQ "5"') +                  
              JFLD((TRPTOPAY/TICK TRPMASTR/TICKET)) +     
              JDFTVAL(*NO) MAPFLD((TICK 'trptopay/ticket'))
 
 
Here's the one without my failed attempt with MAPFLD:
                                                            
  OPNQRYF    FILE((TRPTOPAY) (TRPMASTR)) FORMAT(TRPTOPAY) +
               QRYSLT('STATUS *EQ "5"') +                  
               JFLD((TRPTOPAY/TICKET TRPMASTR/TICKET)) +   
               JDFTVAL(*NO)                                
 
TIA,
Dave

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.