× 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: RE: File field names
  • From: rob@xxxxxxxxx
  • Date: Thu, 26 Oct 2000 08:59:17 -0500


That's your problem, right there.  You're adding a prefix when you code a
PF.  For example, if you called the item number ITEMNUM in both ITEMMAST
and ORDDET then a simple query against the file QSYS/QADBIFLD would show
you everywhere the field is used.  If you want to use the two files in the
same program then you simply do a PREFIX on the F spec in RPGIV.  There are
commercial canned software applications out there which do this.  They
actually work and make sense.  People can adapt.

Adopting this technique makes referencing obsolete.  Except maybe in screen
or printer files.

Rob Berendt

==================
Remember the Cole!


                                                                                
                                       
                    Marco Facchinetti                                           
                                       
                    <facchinetti@yaho        To:     RPG400-L@midrange.com      
                                       
                    o.com>                   cc:                                
                                       
                    Sent by:                 Subject:     RE: File field names  
                                       
                    owner-rpg400-l@mi                                           
                                       
                    drange.com                                                  
                                       
                                                                                
                                       
                                                                                
                                       
                    10/25/00 06:42 PM                                           
                                       
                    Please respond to                                           
                                       
                    RPG400-L                                                    
                                       
                                                                                
                                       
                                                                                
                                       




First of all because I think reference is a basic component
in relational database and it's amazing IBM provides a
system (R in DDS) and grant you all the informations about
a filed except the reference field. Check out the api
format (see the original message) and tell me what else is
missing.

But basicly because I always (at least I try) to define a
field only once and attach comments and help on this field.
I put this field in a file and I use it as a dictionary.
When I code PF I add a prefix of two char to unique
identify the field in/from the PF. This is a basic rule
just to help programmers and doesn't apply to all fields.
To insert help in display files and to print a documented
"DSPFFD" I need the referenced fields. Otherwise I have to
duplicate help pannels and txt members (comments to
fields).

--- Steve Brazzell <steve@brazzell.com> wrote:
> That's true, but I didn't think it was part of the
> original question.
>
> Except for building some sort of metadata reference
> information or
> attempting to glean field purposes (risky, this way,
> btw), why would one
> want to know the referenced field names?
>
> This is just a question, not a put-down in any way; I'm
> just curious.
>
> Steve
>
>
> -----Original Message-----
> From: owner-rpg400-l@midrange.com
> [mailto:owner-rpg400-l@midrange.com]On
> Behalf Of Marco Facchinetti
> Sent: Wednesday, October 25, 2000 7:31 AM
> To: RPG400-L@midrange.com
> Subject: RE: File field names
>
>
> But something is missing, at least in V4R4, the
> referenced
> field.
> --- Steve Brazzell <steve@brazzell.com> wrote:
> > Lance,
> >
> > The purest RPG solution I know of is to use the QUSLRCD
> > API and then read
> > the results from a user space.
> >
> > If you don't care to go this route, though, you can
> > always do a DSPFFD to an
> > outfile and then read the records in the outfile.
> >
> > Steve Brazzell
> >
> >
> > -----Original Message-----
> > From: owner-rpg400-l@midrange.com
> > [mailto:owner-rpg400-l@midrange.com]On
> > Behalf Of Gwecnal@aol.com
> > Sent: Tuesday, October 24, 2000 3:27 PM
> > To: rpg400-l@midrange.com
> > Subject: File field names
> >
> >
> > I seem to remember someone, sometime posting some REXX
> > code that would
> > extract the field names from an externally described
> > file. I did not save
> > the
> > message and now I need to be able to get the field
> names
> > out of a file.  Did
> > anyone keep it or does anyone know how?  TIA, Lance
> > +---
> > | This is the RPG/400 Mailing List!
> > | To submit a new message, send your mail to
> > RPG400-L@midrange.com.
> > | To subscribe to this list send email to
> > RPG400-L-SUB@midrange.com.
> > | To unsubscribe from this list send email to
> > RPG400-L-UNSUB@midrange.com.
> > | Questions should be directed to the list
> > owner/operator:
> > david@midrange.com
> > +---
> >
> > +---
> > | This is the RPG/400 Mailing List!
> > | To submit a new message, send your mail to
> > RPG400-L@midrange.com.
> > | To subscribe to this list send email to
> > RPG400-L-SUB@midrange.com.
> > | To unsubscribe from this list send email to
> > RPG400-L-UNSUB@midrange.com.
> > | Questions should be directed to the list
> > owner/operator: david@midrange.com
> > +---
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Messenger - Talk while you surf!  It's FREE.
> http://im.yahoo.com/
> +---
> | This is the RPG/400 Mailing List!
> | To submit a new message, send your mail to
> RPG400-L@midrange.com.
> | To subscribe to this list send email to
> RPG400-L-SUB@midrange.com.
> | To unsubscribe from this list send email to
> RPG400-L-UNSUB@midrange.com.
> | Questions should be directed to the list
> owner/operator:
> david@midrange.com
> +---
>
> +---
> | This is the RPG/400 Mailing List!
> | To submit a new message, send your mail to
> RPG400-L@midrange.com.
> | To subscribe to this list send email to
> RPG400-L-SUB@midrange.com.
> | To unsubscribe from this list send email to
> RPG400-L-UNSUB@midrange.com.
> | Questions should be directed to the list
> owner/operator: david@midrange.com
> +---


__________________________________________________
Do You Yahoo!?
Yahoo! Messenger - Talk while you surf!  It's FREE.
http://im.yahoo.com/
+---
| This is the RPG/400 Mailing List!
| To submit a new message, send your mail to RPG400-L@midrange.com.
| To subscribe to this list send email to RPG400-L-SUB@midrange.com.
| To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator:
david@midrange.com
+---



+---
| This is the RPG/400 Mailing List!
| To submit a new message, send your mail to RPG400-L@midrange.com.
| To subscribe to this list send email to RPG400-L-SUB@midrange.com.
| To unsubscribe from this list send email to RPG400-L-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---

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.