{"id":163,"date":"2023-07-18T03:09:20","date_gmt":"2023-07-18T03:09:20","guid":{"rendered":"https:\/\/www-c.covariant-systems.com\/?page_id=163"},"modified":"2023-07-18T03:12:14","modified_gmt":"2023-07-18T03:12:14","slug":"calling-adabas-with-acbx","status":"publish","type":"page","link":"https:\/\/www-c.covariant-systems.com\/?page_id=163","title":{"rendered":"Calling ADABAS with ACBX"},"content":{"rendered":"\n<p>Example program <a href=\"https:\/\/www-c.covariant-systems.com\/?page_id=176\" data-type=\"URL\" data-id=\"https:\/\/www-c.covariant-systems.com\/?page_id=176\">ASMADA9<\/a> calls ADABAS version 8.5 with ACBX and multi-fetch to read the sample \u201cEmployee\u201d file number 2.<\/p>\n\n\n\n<p>The ACBX copybook is unchanged however a small modification has been made to the ADABDX macro to allow equates to be expanded and the different ABD\u2019s for format buffer, record buffer, search buffer, value buffer, etc. to be coded (see modified <a href=\"https:\/\/www-c.covariant-systems.com\/?page_id=178\" data-type=\"URL\" data-id=\"https:\/\/www-c.covariant-systems.com\/?page_id=178\">ADABDX<\/a>).<\/p>\n\n\n\n<p>The file is read using descriptor AA (A8) employee number retrieving chunks of 100 records per call. This is unblocked after calling ADABAS by examining each 16 byte entry of the multi-fetch buffer for response code zero, or three (EOF). The number of records returned in the call is indicated in (MBCOUNT), the first full word of the multi-fetch data area.<\/p>\n\n\n\n<p>The JCL to run the assembled\/linked program is as follows, with the ADARUN card specifying PROG=RENTUSER to indicate the fully reentrant ADABAS link module is to be used. The calling parameters to do this are shown in the source of ASMADA9, see contents of nine full words stored into ADAPAL:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/NRUNADA9 JOB (0010),'RUN ASMADA9',                                   \n\/\/          NOTIFY=&amp;SYSUID.,                                           \n\/\/          REGION=0M,                                                 \n\/\/          CLASS=A,                                                   \n\/\/          MSGLEVEL=(1,1),                                            \n\/\/          MSGCLASS=X                                                 \n\/\/*                                                                    \n\/\/         EXPORT SYMLIST=*                                            \n\/\/         SET HLQ=&lt;TSO-ID&gt;                                              \n\/\/         SET MLQ=&lt;PROJECT&gt;                                             \n\/\/*                                                                    \n\/\/JOBLIB   DD DISP=SHR,DSN=&amp;HLQ..&amp;MLQ..LOAD                         \n\/\/         DD DISP=SHR,DSN=SAG.ADA854.LOAD\n\/\/*                                                                    \n\/\/ADAPGM EXEC PGM=GVBADA9\n\/\/*                                                                    \n\/\/SYSOUT    DD   SYSOUT=*                                              \n\/\/SYSPRINT  DD   SYSOUT=*                                   \n\/\/DDPRINT   DD   SYSOUT=*                                   \n\/\/DDDRUCK   DD   SYSOUT=*                                   \n\/\/DDODATA   DD   DISP=SHR,DSN=&amp;HLQ..&amp;MLQ..ADAF002   \n\/\/*                                                         \n\/\/DDCARD    DD   *                                          \nADARUN PROG=RENTUSER,MODE=MULTI,SVC=245,DEVICE=3390,DBID=300\n\/*<\/code><\/pre>\n\n\n\n<p>Sample output is show below:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>ASMADA: OPEN DONE                                                          \nASMADA: READ DONE 11100102EDGAR               PETER               SCHINDLER\nASMADA: READ DONE 11100105CHRISTIAN                               SCHIRM   \n..................\n.. many records ..\n..................\nASMADA: READ DONE 60016228SONIA               JACOTOT             MARTINEZ     \nASMADA: READ DONE 60016231ARTURO              DE LA HOZ           SERRANO      \nASMADA: READ DONE 60016233JORGE               BELTRAN             DE LA IGLESIA\nASMADA: READ DONE 60016287ROBERTO                                 OSEA         \nASMADA: END OF DATA                                                            \nASMADA: CLOSE DONE                                                             \nASMADA9: Records read:   1107                                                  \nASMADA9: Using L3 commands:     12                                 <\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Example program ASMADA9 calls ADABAS version 8.5 with ACBX and multi-fetch to read the sample \u201cEmployee\u201d file number 2. The ACBX copybook is unchanged however a small modification has been made to the ADABDX macro to allow equates to be expanded and the different ABD\u2019s for format buffer, record buffer, search buffer, value buffer, etc. &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www-c.covariant-systems.com\/?page_id=163\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Calling ADABAS with ACBX&#8221;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-163","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=\/wp\/v2\/pages\/163","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=163"}],"version-history":[{"count":23,"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=\/wp\/v2\/pages\/163\/revisions"}],"predecessor-version":[{"id":204,"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=\/wp\/v2\/pages\/163\/revisions\/204"}],"wp:attachment":[{"href":"https:\/\/www-c.covariant-systems.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=163"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}