× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



From: Ken Mitchell <madmitch76@hotmail.com>
> Only about 6 weeks MI experience here
>
> Can anyone enlighten me as to the proper way to do something like this?
>

Ken,
having looked at what you did, I can suggest the following two
approaches. The first one takes a copy of the data, which is
convenient if you need to materialize other stuff. The second
one works with the data in place. You were trying to do a mixture
of the two and got your ears in the "clipper".

Method 1:

DCL DD VPDMEM CHAR(2);
DCL SPCPTR .VPDMEM INIT(VPDMEM);
DCL SPC MEM BAS(.VPDMEM);
   DCL DD TOTMEM           BIN(2)    DIR;

DCL DD VPDCEC CHAR(48);
DCL SPCPTR .VPDCEC INIT(VPDCEC);
DCL SPC CEC BAS(.VPDCEC);
   DCL DD STSCECLSTREAD    CHAR(4)   DIR;
   DCL DD SYSMANID         CHAR(4)   DIR;
   DCL DD *                CHAR(4)   DIR;
   DCL DD SYSTYPE          CHAR(4)   DIR;
   DCL DD MODELNBR         CHAR(4)   DIR;
   DCL DD PSDMODNBR        CHAR(4)   DIR;
   DCL DD PRCGRP           CHAR(4)   DIR;
   DCL DD *                CHAR(4)   DIR;
   DCL DD SYSTYPEXT        CHAR(1)   DIR;
   DCL DD SYSPRCFEAT       CHAR(4)   DIR;
   DCL DD SYSSRLNBR        CHAR(4)   DIR;

DCL DD MATMATR_RQS CHAR(2);

DCL DD MATERIALIZE-AREA CHAR(2608) BDRY(16);
DCL SPCPTR .MACHINE-ATTR  INIT(MATERIALIZE-AREA);
DCL SPC     MACHINE-ATTR  BAS(.MACHINE-ATTR);
DCL DD  BYTES-PROVIDED  BIN(4) DIR;
DCL DD  BYTES-AVAILABLE BIN(4) DIR;
DCL DD  *              CHAR(8) DIR;
DCL DD  OFFMEMVPD       BIN(4) DIR;
DCL DD  OFFPRCVPD       BIN(4) DIR;
DCL DD  OFFCOLCOL       BIN(4) DIR;
DCL DD  OFFCECVPD       BIN(4) DIR;
DCL DD  OFFPNLVPD       BIN(4) DIR;

DCL SPCPTR .DATA;
DCL DD DATA CHAR(32760) BAS(.DATA);

CPYBLA    MATMATR_RQS, X'012C';
CPYNV     BYTES-PROVIDED, 2608;

MATMATR  .MACHINE-ATTR, MATMATR_RQS;
ADDSPP   .DATA, .MACHINE-ATTR, OFFMEMVPD;
CPYBLA    VPDMEM, DATA;

ADDSPP   .DATA, .MACHINE-ATTR, OFFCECVPD;
CPYBLA    VPDCEC, DATA;

BRK "1";

Method two:

DCL SPCPTR .VPDMEM;
DCL SPC MEM BAS(.VPDMEM);
   DCL DD TOTMEM           BIN(2)    DIR;

DCL SPCPTR .VPDCEC;
DCL SPC CEC BAS(.VPDCEC);
   DCL DD STSCECLSTREAD    CHAR(4)   DIR;
   DCL DD SYSMANID         CHAR(4)   DIR;
   DCL DD *                CHAR(4)   DIR;
   DCL DD SYSTYPE          CHAR(4)   DIR;
   DCL DD MODELNBR         CHAR(4)   DIR;
   DCL DD PSDMODNBR        CHAR(4)   DIR;
   DCL DD PRCGRP           CHAR(4)   DIR;
   DCL DD *                CHAR(4)   DIR;
   DCL DD SYSTYPEXT        CHAR(1)   DIR;
   DCL DD SYSPRCFEAT       CHAR(4)   DIR;
   DCL DD SYSSRLNBR        CHAR(4)   DIR;

DCL DD MATMATR_RQS CHAR(2);

DCL DD MATERIALIZE-AREA CHAR(2608) BDRY(16);
DCL SPCPTR .MACHINE-ATTR  INIT(MATERIALIZE-AREA);
DCL SPC     MACHINE-ATTR  BAS(.MACHINE-ATTR);
DCL DD  BYTES-PROVIDED  BIN(4) DIR;
DCL DD  BYTES-AVAILABLE BIN(4) DIR;
DCL DD  *              CHAR(8) DIR;
DCL DD  OFFMEMVPD       BIN(4) DIR;
DCL DD  OFFPRCVPD       BIN(4) DIR;
DCL DD  OFFCOLCOL       BIN(4) DIR;
DCL DD  OFFCECVPD       BIN(4) DIR;
DCL DD  OFFPNLVPD       BIN(4) DIR;

DCL SPCPTR .DATA;
DCL DD DATA CHAR(32760) BAS(.DATA);

CPYBLA    MATMATR_RQS, X'012C';
CPYNV     BYTES-PROVIDED, 2608;

MATMATR  .MACHINE-ATTR, MATMATR_RQS;
ADDSPP   .VPDMEM, .MACHINE-ATTR, OFFMEMVPD;
ADDSPP   .VPDCEC, .MACHINE-ATTR, OFFCECVPD;

BRK "1";





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.