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



I am certain there are better ways to accomplish your goal than I am
going to suggest you try, but in case you need a solution now and
better responses are slow in coming...

Idea #1:
Call the Cobol program with the parameter specified in hexadecimal. 
For example, if you wanted to use 123456 as the parameter value, you
would use this:
       CALL   COBOLPGM  PARM( X'F1F2F3F4F5F6' )
Of course, if you are dealing with a variable, you might have to build
the above command string and invoke it via QCMDEXC.  I.e.:
       CHGVAR  &CMD VALUE('CALL   COBOLPGM  PARM( X''' *CAT
                   &HEXZONED *CAT ''' )' )
       CALL    QCMDEXC  PARM( &CMD  100 )
You would have to figure a way to build the value for &HEXZONED.  BTW,
I'm not really sure the hex idea would work.  Before you go coding to
build the value for &HEXZONED, I would suggest you try a hard-coded
call (the example call with the PARM( X'F1F2F3F4F5F6' ))

Idea #2:
If you have the RPG compiler, create an RPG program that takes the CL
packed variable as an *Entry parameter, move that variable to a data
structure subfield defined as zoned.  (Question:  Can you use a DS
subfield as a parameter to call another program?)  Non-ILE RPG may be
the best to try as I think ILE-RPG defaults zoned definitions to packed
internally.  Maybe you can do a similar trick in Cobol?

HTH, Dan

--- Senkathiravan Athiappan <senkathiravan.athiappan@wipro.com> wrote:
> Hallo -
> 
> We need to pass a parameter from CLP to COBOL.
> 
> The entry parameter in COBOL is of attribute- length 6 and type
> Zoned.
> 
> I have the limitation of not doing any change to the Cobol program.
> 
> How should, I pass the Zoned field of length 6 from the CLP when I
> call
> the cobol program???
> 
> Pls., explain.
> 
> Regards,
> 
> Kathir



__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.