|
|
| Author |
Message |
muthukumarapandian
New User
Joined: 08 Oct 2004 Posts: 44 Location: chennai, india
|
|
|
|
Hi,
The size of the commarea is 64 kb if i want to store more than that means is it possible or not. |
|
| Back to top |
|
 |
References
|
|
 |
rick
Moderator
Joined: 18 Jun 2004 Posts: 61 Location: Kuzhithurai
|
|
|
|
Hi,
It is not possible to have DFHCOMMAREA more than 64KB.
Thanks and Regards,
Rick. |
|
| Back to top |
|
 |
meetsrk
Active User
Joined: 13 Jun 2004 Posts: 86
|
|
|
|
hi,
I suspect its not 64KB, its 32KB.
if u wanna store more than 32KB, then go for TSQ(Temporary storage queue). |
|
| Back to top |
|
 |
mcmillan
Site Admin
Joined: 18 May 2003 Posts: 918 Location: India
|
|
|
|
Dear Metsrk,
You are correct. The maximum size of DFHCOMMAREA is 32,500 bytes, however it is recommended (by IBM) not to exceed 24K. |
|
| Back to top |
|
 |
ganmain
New User
Joined: 19 Feb 2005 Posts: 25
|
|
|
|
HI,
I want to know why we are declaring commarea in both working
storage & linkage section(dfhcommarea).
if my cics program is not calling another program
only commarea declaring in working storage section is enough
or
we have to declare both in working storage & linkage section ?
please clarify this doubt |
|
| Back to top |
|
 |
mcmillan
Site Admin
Joined: 18 May 2003 Posts: 918 Location: India
|
|
|
|
| Quote: |
why we are declaring commarea in both working
storage & linkage section |
The COMMAREA option of the LINK and XCTL commands specifies the name of a data area (known as a communication area) in which data is passed to the program being invoked.
| Quote: |
| if my cics program is not calling another program only commarea declaring in working storage section is enough |
If you are not using any LINK, XCTL or RETURN command in your program, there is no need to worryabout COMMAREA.
| Quote: |
| we have to declare both in working storage & linkage section |
In a receiving COBOL program, you must give the data area the name DFHCOMMAREA. In this COBOL program, if a program passes a COMMAREA as part of a LINK, XCTL, or RETURN command,
either the working-storage or the LINKAGE SECTION can contain the data area. A program receiving a COMMAREA should specify the data in the LINKAGE SECTION. |
|
| Back to top |
|
 |
ganmain
New User
Joined: 19 Feb 2005 Posts: 25
|
|
|
|
thanks for your reply
but still iam having doubt in that
if my program is of psudo conversation ie return(transid) but it is not
calling another program then declaring dfhcommarea in linkage section is necessary or not necessary?
please clarify this |
|
| Back to top |
|
 |
mainframemouli
Active User
Joined: 01 Mar 2005 Posts: 53 Location: Mysore
|
|
|
|
Even if you are not including the DFHCOMMAREA the system will automatically include it in the program.
If your program uses a Psued0-conversational then You also include the COMMAREA option to name the area of working storage that will be stored in the CICS communication area between program executions. When the RETURN command is issued in this form, the program associated with the trans-id will be started the next time the user presses an attention key |
|
| Back to top |
|
 |
manoj_madhavan Warnings : 1 New User
Joined: 07 Mar 2005 Posts: 12
|
|
|
|
but sir ....it is necessary for a commarea declaration only when u pass some value through the commarea...
else is it necessary for a separate definition both in the workin storage as well as linkage section? |
|
| Back to top |
|
 |
mcmillan
Site Admin
Joined: 18 May 2003 Posts: 918 Location: India
|
|
|
|
| Quote: |
| Is it necessary for a separate definition both in the workin storage as well as linkage section |
Yes. if you want to pass X from Program A to B, then
X should be declared in Working Storage Section of Program A and it can be received to a varialbe named DFHCOMMAREA which is declared in the Linkage section of Porgram B.
| Code: |
? ?
? Invoking program ?
? IDENTIFICATION DIVISION. ?
? PROGRAM ID. 'PROG1'. ?
? . ?
? . ?
? . ?
? WORKING-STORAGE SECTION. ?
? 01 COM-REGION. ?
? 02 FIELD PICTURE X(3). ?
? . ?
? . ?
? . ?
? PROCEDURE DIVISION. ?
? MOVE 'ABC' TO FIELD. ?
? EXEC CICS LINK PROGRAM('PROG2') ?
? COMMAREA(COM-REGION) ?
? LENGTH(3) END-EXEC. ?
? . ?
? . ?
? . ?
? Invoked program ?
? IDENTIFICATION DIVISION. ?
? PROGRAM-ID. 'PROG2'. ?
? . ?
? . ?
? . ?
? LINKAGE SECTION. ?
? 01 DFHCOMMAREA. ?
? 02 FIELD PICTURE X(3). ?
? ?
? . ?
? . ?
? . ?
? PROCEDURE DIVISION. ?
? IF EIBCALEN GREATER ZERO ?
? THEN ?
? IF FIELD EQUALS 'ABC' ... ? |
|
|
| Back to top |
|
 |
manoj_madhavan Warnings : 1 New User
Joined: 07 Mar 2005 Posts: 12
|
|
|
|
i was asking the declaration situation when u dont pass in any parameters.......ie, u dont use commrea for passing values but simply return with a transaction id without any parameters.....
in such a situation is it necessary to have declararion for commarea and dfhcommarea?? |
|
| Back to top |
|
 |
mcmillan
Site Admin
Joined: 18 May 2003 Posts: 918 Location: India
|
|
|
|
| Quote: |
| in such a situation is it necessary to have declararion for commarea and dfhcommarea?? |
No. |
|
| Back to top |
|
 |
sarma Kappagantu
New User
Joined: 17 Mar 2005 Posts: 22 Location: Bangalore
|
|
|
|
Commarea passed with XCTL & LINK can be 32,673 bytes at the max. (4 bytes less than 32K - 1. However, it is 24K on RETURN command.
CICS Application Programming Guide specifies that "The length of a COMMAREA on a RETURN command can vary from transaction to transaction, up to a theoretical upper limit of 32,763 bytes. However to be safe, you should not exceed 24KB ?, because of a number of factors that can reduce the limit from the theoretical maximum.?
If you wish to pass more than 24 KB, you may use BTS container, if the version of CICS is CICS TS1.3 or higher. |
|
| Back to top |
|
 |
kavi
New User
Joined: 03 Mar 2005 Posts: 2
|
|
|
|
You can use getmain to get the maximum address and by pointer reference you can acess the data.
The size of the DHFCOMMAREA is 64kb and it is not 32 kb reply to me if i am wrong. |
|
| Back to top |
|
 |
raguibmm
New User
Joined: 16 Mar 2005 Posts: 4
|
|
|
|
Commarea passed with XCTL & LINK can be 32,673 bytes at the max. (4 bytes less than 32K - 1. However, it is 24K on RETURN command.
CICS Application Programming Guide specifies that "The length of a COMMAREA on a RETURN command can vary from transaction to transaction, up to a theoretical upper limit of 32,763 bytes. However to be safe, you should not exceed 24KB ?, because of a number of factors that can reduce the limit from the theoretical maximum.?
If you wish to pass more than 24 KB, you may use BTS container, if the version of CICS is CICS TS1.3 or higher.
what is bts container? |
|
| Back to top |
|
 |
|
|