Ü Library in AS400  

 

·         When we execute a command or call a program, the AS/400 must know where to find the command or program and the answer is library.

·         A Library is a collection of objects.

·         QSYS is the only library that contains other library.

·         A library contain the object name, type, and the address

·         QSYS is the root library where the entire user defined/ system defined library is created.

·         System library is the library that contains the objects that was created at the time OS400 was installed.

·         System supplied libraries begin with the letter "Q" or "#".

·         When you logon the first library to be load is QSYS. The system library is loaded at the first time.

 

Library list types in AS400


·         System library: All IBM supplied library e.g. QSYS, QHLPSYS, QUSRSYS…

·         Product Library: Whenever Ibm product is used it is added to the library automatically and is removed itself when    the job completes.

·         Current Library: Current library is the working library i.e. all the work done by you is stored in current library. If you want that all the things done by you should be stored in your personal library ‘AMINEM’ , then just change the current library as your personal library.

To change current library to your personal library AMINEM: CHGCURLIB    AMINEM

·         User Library: Non-IBM supplied i.e. created by the user.

 

Library in as400

 



Library commands in AS400

 


      I.        Display Library List (DSPLIBL)

 

To display all types of libraries, we can use the command:

In the below snapshot we can see different types of library in the library list

e.g. SYS(system), CUR(current), USR(user) library.


                              Display Library List                              
                                                             System:   SYSTEM09 
Type options, press Enter.                                                     
   5=Display objects in library                                                 
                                                                                
                            ASP                                                 
 Opt  Library     Type      Device      Text                                    
      QSYS        SYS                   System Library                          
      QSYS2       SYS                   System Library for CPIs                
      QHLPSYS     SYS                                                           
      QUSRSYS     SYS                   System Library for Users                
      AMINEM      CUR                                                           
      QGPL        USR                   General Purpose Library                 
      QTEMP       USR                                                           
      LOAD        USR                   Future Three - LOAD Procedure & Update  
                                                                        More... 
 F3=Exit   F12=Cancel   F17=Top   F18=Bottom  

 

 

    II.        Create Library (CRTLIB)

 

 

To create library the command is: CRTLIB  IROBO1 è Press F4

 


Type choices, press Enter.	 

 	Library . . . . . . . . . . . . IROBO1 Name 
 	Library type . . . . . . . . . . *TEST (*PROD, *TEST)
 	Text  description . . . . . . . THIS IS IROBO TEST LIBRARY 



 	Bottom 
 	F3=Exit F4=Prompt F5=Refresh F10=Additional parameters F12=Cancel 
 	F13=How to use this display F24=More keys

 

Library type (TYPE)

 

ü  *PROD

Database files in production libraries cannot be opened for updating if a user is in debug mode and he requested that production libraries be protected.

                                            A user can protect all database files in production libraries from updates by specifying *NO for the Update production files (UPDPROD) parameter on the Start Debug (STRDBG) command to begin testing. However, this protection does not prevent the program from deleting database files or from changing other objects (such as data areas) in the library.

 

ü  *TEST

This is a test library. All objects in a test library can be updated during testing, even if special protection is requested for production libraries.

 

 


 

   III.        Display library (DSPLIB)

 

DSPLIB IROBO1

 

It gives you the information of all objects that resides in the library with its            size.               

 


                                Display Library                                 
                                                                                
 Library  . . . . . . :   IROBO1          Number of objects  . :   8            
 Type . . . . . . . . :   PROD            Library ASP number . :   1            
 Create authority . . :   *EXCLUDE        Library ASP device . :   *SYSBAS      
                                                                                
 Type options, press Enter.                                                     
   5=Display full attributes   8=Display service attributes                     
                                                                                
 Opt  Object      Type      Attribute               Size  Text                  
      PRINT1PGM   *PGM      RPGLE                 131072  rpgle program for pri 
      ACCOUNT     *FILE     PF                     49152  ACCOUNT RELATED INFOR 
      PRINT1      *FILE     PRTF                    4096  PRINTER DDS RLU GENER 
      QCLSRC      *FILE     PF                      8192  Sources CL-Programs   
                                                                                
                                                                                
                                                                         Bottom 
 F3=Exit   F12=Cancel   F17=Top   F18=Bottom  

 

  IV.        Edit Library List (EDTLIBL)

 

You can add your personal library to any position just update the sequence no. “0” with the required where you want your library to be and the corresponding library name.

 


                        Edit Library List
                                                      System:   PUB1
Type new/changed information, press Enter.

Sequence                   Sequence                  Sequence
Number   Library           Number   Library          Number   Library
 0                        150                        300
10    GAMES400            160                        310
20    QGPL                170                        320
30    QTEMP               180                        330
40                        190                        340
50                        200                        350


 

 

   V.        Add Library List Entry (ADDLIBLE)

 

ADDLIBLE LIB(IROBO1) POSITION(*First)

 

It adds your personal library at the first position in the library list.

 

 

  VI.        Work With Libraries Using PDM (WRKLIBPDM)

 




 

 







User Comments:



Subscribe

.  


Copyright © www.go4as400.com, 2013-2023. Copyright notice   Terms of services   Privacy policy