     H dftactgrp( *no )  OPTION(*NODEBUGIO)  BndDir( 'QC2LE' )                                      
     F********************************************************************                          
     F*  Program Name -- LIBRARYLIS                                                                 
     F*  Written By   --            Date Written  --                                                
     F********************************************************************                          
     F*  List all modifications to this program below in the                                        
     F*  format of initials, date & description of your change.                                     
     F*                                                                                             
     F*  Initials    Date    Description                                                            
     F*   x.x.x.   xx/xx/xx  xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx                             
     F********************************************************************                          
     F*                   *-* PROGRAM DESCRIPTION *-*                                               
     F*                                                                                             
     F*  This program will:                                                                         
     F*                                                                                             
     F********************************************************************                          
      *                                                                                             
      * Defined variables                                                                           
      *                                                                                             
     d i               s             10i 0 inz                                                      
     d MaxItemLines    s             10i 0 inz(200)                                                 
     d MyOutput        s             20    inz                                                      
     d reply           s              1    inz                                                      
     d RowCount        s             10i 0 inz                                                      
      *-----------------------------------------------------------------                            
      * program status dataarea                                                                     
      *-----------------------------------------------------------------                            
     d PgmSts         sds                                                                           
     d   P1User              254    263                                                             
     d   @PGM            *PROC                                                                      
     d  @JOB                 244    253                                                             
      *                                                                                             
     d C1              ds                  Dim(200) Qualified                                       
     d  sequenceNumber...                                                                           
     d                               10i 0                                                          
     d  schemaName                   10a                                                            
                                                                                                    
                                                                                                    
              exec sql  set option commit=*none,datfmt=*iso,                                        
                            closqlcsr=*ENDMOD;                                                      
                                                                                                    
              *inlr = *on;                                                                          
                                                                                                    
              exec SQL                                                                              
               declare  c1 scroll cursor for                                                        
               select * from qsys2.library_List_info                                                
               for read only;                                                                       
                                                                                                    
              exec SQL open c1;                                                                     
              exec sql fetch first from C1 for :MaxItemLines rows into :C1;                         
              exec sql get diagnostics :RowCount = ROW_COUNT;                                       
              DoW RowCount <> 0;                                                                    
               For i = 1 to RowCount;                                                               
                myOutput = %trim(%char(c1(i).sequenceNumber)) + '_' +                               
                           %trim(c1(i).schemaName);                                                 
                dsply myOutput;                                                                     
               EndFor;                                                                              
               exec sql fetch next from C1 for :MaxItemLines rows into :C1;                         
               exec sql get diagnostics :RowCount = ROW_COUNT;                                      
              EndDo;                                                                                
              exec sql close C1;                                                                    
                                                                                                    
       //********************************************************************                       
      /End-Free                                                                                     
