[Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 2151
  • Last Modified:

Self Join Logical File- DDS

Good Morning Every one.
Can any please provide me the DDS Specification for a Self Join Logical File.
& is their any Special way to Compile that of the same.
0
midwestexp
Asked:
midwestexp
1 Solution
 
_b_hCommented:
If the physical file PF has three fields like this:
A          R FM1                                              
A            USRPRF        10          TEXT('USER PROFILE')    
A            DESC          30          DFT('BLANK')            
A                                      TEXT('DESCRIPTION')    
A            GRPPRF        10          TEXT('GROUP PROFILE')  
where user profile USRPRF is in group profile GRPPRF

The DDS for join logical file JLF is:
A                                      JDFTVAL                  
A          R JFM                       JFILE(PF PF)              
A          J                           JOIN(1 2)                
A                                      JFLD(GRPPRF USRPRF)      
A            USRPRF                    JREF(1)                  
A            DESC                      JREF(1)                  
A            GRPPRF                    RENAME(USRPRF)            
A                                      JREF(2)                  
A            GROUPDES                  RENAME(DESC)              
A                                      JREF(2)                  

So, if the physical file looks like:
USRPRF      DESC                            GRPPRF
----------     -------------------------     ----------
BH              Barry                            SECADM
SECADM      Security Admin Group  
               
The resulting join logical file looks like:
USRPRF      DESC                            GROUPNAM  GROUPDES                    
---------      --------------------------    -------------  ------------------------
BH              Barry                            SECADM      Security Admin Group    
SECADM     Security Admin Group                        BLANK                  

I included a default value for the description field so you can see how it works.
If you have any questions, please post back!
Barry
0

Featured Post

Upgrade your Question Security!

Add Premium security features to your question to ensure its privacy or anonymity. Learn more about your ability to control Question Security today.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now