473,406 Members | 2,894 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

DB2/COBOL Stored Procedure Parameter list

JLE
I'm new to stored procedures, however, the passing of parameters using a
group item in the calling cobol program seems incorrect to me. Would
this work?

Calling COBOL pgm is calling a stored procedure using a group 01 level
and the receiving COBOL procedure has 01 levels for each parameter.

Environment is z/OS, DB2, CICS, COBOL, LE. The procedure is local using
WLM. DB2 version is 7.x and CICS is TS 2.2, I think.

Caller WS
01 ws-all5-parms.
05 ws parm1
05 ws-parm2
05 ws-parm3
05 ws-parm4
05 ws-parm5
Exec sql call called-procedure :ws-all5-parms

Receiving procedure

Linkage
01 ws parm1
01 ws-parm2
01 ws-parm3
01 ws-parm4
01 ws-parm5

procedure division using
ws parm1
ws-parm2
ws-parm3
ws-parm4
ws-parm5

The reason I am questioning this is because I have yet to see an example
like this. All of the examples I have seen from IBM match 01 levels in
the caller and called programs. Each parameter is coded as a 01 level
and none are passed as a group item, except null indicators and varchar,
I believe.

John
Mar 2 '06 #1
1 5699
wfs
No.

- you'd get an error saying something like 'no procedure found that
matches the procedure definition....'

Bill
"JLE" <jo**@j.j> wrote in message news:xFqNf.53391$3W5.52787@trnddc02...
I'm new to stored procedures, however, the passing of parameters using a
group item in the calling cobol program seems incorrect to me. Would
this work?

Calling COBOL pgm is calling a stored procedure using a group 01 level
and the receiving COBOL procedure has 01 levels for each parameter.

Environment is z/OS, DB2, CICS, COBOL, LE. The procedure is local using
WLM. DB2 version is 7.x and CICS is TS 2.2, I think.

Caller WS
01 ws-all5-parms.
05 ws parm1
05 ws-parm2
05 ws-parm3
05 ws-parm4
05 ws-parm5
Exec sql call called-procedure :ws-all5-parms

Receiving procedure

Linkage
01 ws parm1
01 ws-parm2
01 ws-parm3
01 ws-parm4
01 ws-parm5

procedure division using
ws parm1
ws-parm2
ws-parm3
ws-parm4
ws-parm5
The reason I am questioning this is because I have yet to see an
example
like this. All of the examples I have seen from IBM match 01 levels in
the caller and called programs. Each parameter is coded as a 01 level
and none are passed as a group item, except null indicators and varchar, I
believe.

John

Mar 7 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Steven | last post by:
I'm calling a stored procedure which has an output parameter of type int. Once the stored procedure is executed, I want to check the value of the parameter in case it is null. However, when the a...
6
by: Bala | last post by:
Hi, This is my stored procured. i try to pass the parametre like this. i am getting error. any one please tell me how to pass the parameter? vb code: ..Connection = New...
3
by: Dj | last post by:
If you passed all of the fields as one group level when you rejester the SP you would only be able to use one CHAR field. Now here is the rub. If you are passing mix data, why not send it in the...
7
by: CK | last post by:
I want the procedure to check for the existence of a paramter and if it is there, it will process these instructions, otherwise it will process these instructions. Any ideas? Thanks for your...
0
by: Khushboo Chhabra | last post by:
Hello, I’m working on mainframes platform and have been trying to collect some knowledge on Stored Procedures. I referred to IBM’s red book. And found details regarding how to create stored...
0
by: pompeyoc | last post by:
I am trying to learn how to use stored procedures written in COBOL so I wrote 2 small programs to test it out: the stored procedure and the the calling program. I have no problems compiling them...
4
by: PJackson | last post by:
I have been given the task of taking a 3,200 line COBOL stored procedure and duplicating the same functionality in UDB 7.2 on the Windows platform with a procedural SQL stored procedure. I have...
0
by: MicheleW | last post by:
Can some tell me how to call a db2 cobol stored procedure in visual studio.net 2005? Thank you.
1
by: rsreeni | last post by:
Hi, We are planning to use Cobol Stored procedures for doing our Data retrieval from DB2 Tables. The stored procedure(s) will be called from J2EE application via Db2 Connect. Does the linkage...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.