× 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.



[ Converted text/html to text/plain ]

Thank You to all on the List.

I have it working now.

I made the changes as John Mentioned below.

I made one long variable and concatenated the other fields into it.

The problem was that in the Cobol program the parameters in the Linkage was
defined at various levels;
01-Level, 05-Level etc. etc.

As this is an program supplied as part of a package (AWD from DST) I do not
want to go and change the program.

But I applied the changes as suggested and now it works!!!

Thank You once more.

And John, I'm from Cape Town, South Africa.

Thanks

Dennis Nel
Technical Consultant: AS/400

*       DNel3@oldmutual.com <mailto:Dnel3@oldmutual.com[1]>
*       (021) 509-3459
*       (082) 808-2687
*       Cape Town, South Africa.

-----Original Message-----
From: John.Part@bif.ie [mailto:John.Part@bif.ie[2]]
Sent: 09 October 2001 03:33
To: DNel3@oldmutual.com
Subject: Re: Parameter List from CL to Cobol

Re-reading your question (I'm sometimes from the "who needs the manual"
school), the answer to your question is, define a large variable in CL and
add the variables to it.

For example:-

DCL VAR(&PARM)  TYPE(*CHAR) LEN(200).

CHGVAR &PARM VALUE(&VAR1 *CAT &VAR2 *CAT &VAR3............)

The only problem you will have is with the variable defined as *DEC (I
think, can't remember off hand if you can concatenate a decimal field).

The other thing I noticed is that you have a values statement in your cobol
code, when you put something in the linkage section, you are not allowed to
use the values statement, as these variables are populated from the calling
program.

Another thing to watch out for, is the lenght of this CL variable, remember
any variable defined as COMP-3 (Cobol) or type(*dec) (CL) is half the
defined size plus 1 eg 9(05) comp-3 takes up 3 bytes of space.

JP


                    Nel Dennis
                    <DNel3@OLDMUTUAL.co       To:     cobol400-l@midrange.com
                    m>                        cc:
                    Sent by:                  Subject:     Parameter List from
CL to Cobol
                    cobol400-l-admin@mi
                    drange.com


                    09/10/01 09:03
                    Please respond to
                    cobol400-l



[ Converted text/html to text/plain ]

hi, I have the following linkage section in a Cobol program, if I want to
call
this program from within a CL program.
How should I define the variables within the CL program?

01  0500-ACBL1001-LINKAGE.
    05  ACBL1001-REQUEST-AREA.
        10  ACBL1001-USERID     PIC  X(08)     VALUE SPACES.
        10  ACBL1001-STATION    PIC  X(08)     VALUE SPACES.
        10  ACBL1001-REQUEST-TYPE
                                PIC  X(01)     VALUE ZEROES.
            88  ACBL1001-REQUEST-LOG           VALUE "L".
            88  ACBL1001-REQUEST-READ          VALUE "R".
            88  ACBL1001-REQUEST-BOTH          VALUE "B".
        10  ACBL1001-CONTINUE   PIC  X(01)     VALUE "N".
            88  ACBL1001-CONTINUE-YES          VALUE "Y".
            88  ACBL1001-CONTINUE-NO           VALUE "N".
        10  ACBL1001-PROGRAMID  PIC  X(10)     VALUE SPACES.
        10  ACBL1001-PROGRAMVR  PIC  X(05)     VALUE SPACES.
        10  ACBL1001-COUNTRYCD  PIC  9(03)     COMP-3
                                               VALUE ZEROES.
        10  ACBL1001-ERROR-RETURN
                                   PIC  X(07)     VALUE SPACES.
               88  ACBL1001-NO-ERROR              VALUE SPACES.
               88  ACBL1001-ERROR-IVRQTYP         VALUE "IVRQTYP".
               88  ACBL1001-ERROR-NOFOUND         VALUE "NOFOUND".
               88  ACBL1001-ERROR-W99ERR          VALUE "W99ERR ".
               88  ACBL1001-ERROR-W42ERR          VALUE "W42ERR ".
               88  ACBL1001-ERROR-W50ERR          VALUE "W50ERR ".
    05  ACBL1001-MESSAGE-AREA.
        10  ACBL1001-RETURNCD   PIC  X(07)     VALUE SPACES.
        10  ACBL1001-PROGRAMSEQ PIC  9(03)     VALUE ZEROES.
        10  ACBL1001-RETURNMSG  PIC  X(78)     VALUE SPACES.

In particular I'm having problems with the Pic 9(03) Comp-3 !!!! (I think)

Thanks
Dennis Nel
Technical Consultant: AS/400

*       DNel3@oldmutual.com
(       (021) 509-3459
È       (082) 808-2687
_______________________________________________
This is the COBOL Programming on the iSeries/AS400 (COBOL400-L) mailing
list
To post a message email: COBOL400-L@midrange.com
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/cgi-bin/listinfo/cobol400-l[3]
or email: COBOL400-L-request@midrange.com
Before posting, please take a moment to review the archives
at http://archive.midrange.com/cobol400-l[4].

**********************************************************************
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

postmaster@bif.ie
**********************************************************************

ÝÝReferences:ÝÐ 1. mailto:Dnel3@oldmutual.com
  2. mailto:John.Part@bif.ie
  3. http://lists.midrange.com/cgi-bin/listinfo/cobol400-l
  4. http://archive.midrange.com/cobol400-l



As an Amazon Associate we earn from qualifying purchases.

This thread ...


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.