RPGIV @ Work

A unique site for RPG and System i Lovers

Welcome!

Hi, this site will provide all what you need in System i and RPG developments.

My Name is Chamara Withanachchi, System i Expert and RPG Developer. And in the field for last 11 years.

I hope you will find lot of valuable information from this site

Example of using QDBBRCDS API Print E-mail
User Rating: / 0
PoorBest 
Written by Chamara Withanachchi   
Example of using QDBBRCDS API
     //---------------------------------------------------------
      // f_BringDataBaseRecords
      // asynchronously bring records into memory
      //---------------------------------------------------------
     p f_BringDataBaseRecords...
     p                 B                   export
     D f_BringDataBaseRecords...
     D                 PI
     D i_file                        10a   const
     D i_lib                         10a   const
     D i_mbr                         10a   const
     D i_numrecs                     10i 0

     D ArryOfRRN       s             10i 0 dim(1000)
     D xx              s             10i 0
     D yy              s             10i 0
      /free
         if i_Numrecs > 1000;
             yy = 1000;
         else;
             yy = i_NumRecs;
         endif;

         for xx = 1 to yy;
            ArryOfRRN(xx) = xx;
         endfor;

         callp QDBBRCDS(
              i_file + i_lib:
              i_mbr:
              ArryOfRRN:
              yy:
              ApiErrDS);
        return;
      /end-free
     p f_BringDataBaseRecords...
     p                 E

More details about QDBBRCDS can be found here


User Comments

Please login or register to add comments

<Previous   Next>