View previous topic :: View next topic
|
Author |
Message |
ignich7
New User
Joined: 02 Nov 2005 Posts: 66
|
|
|
|
Hi..
Thanks for looking into this. I have 2 questions.
1. I believe, the maximum size of the TSQ is 32763. Is it for both aux TSQ and Main TSQ? I am using aux TSQ. What should i do if it reached 32762?
Is it possible to increase this size?
2. My WRITEQ TS fails with ITEMERR since it reached maximum limit. Please let me know what should be done to fix ITEMERR.
Please answer both :-) |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
1. The length of a single item is limited to 32763 bytes. If you are attempting to write out more than 32763 bytes, split the queue record into multiple items and write each separately. If you have to use TS queues, you cannot exceed this limit.
2. ITEMERR means you've written 32767 items (or you are attempting to write an item number greater than 32767 at least). Keep the number of items on a TS queue under 32768, period. If you have more to write, use another queue name! |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
What is the length of each ITEM which you've written? As you've said, the maximum-length for a single ITEM is 32763 and that ceiling can't be changed.
If you're getting an ITEMERR on a WRITEQ (you've exceeded 32767 Items --- W O W!) then you probably need to "rethink" this and to use a VSAM "workfile" instead.
If you're using CICS/TS V3, then review CHANNELS/CONTAINERS, which have been discussed several many times on the CICS forum or review the applicable CICS manual.
Bill |
|
Back to top |
|
|
ignich7
New User
Joined: 02 Nov 2005 Posts: 66
|
|
|
|
Thank you to both of you |
|
Back to top |
|
|
Bill O'Boyle
CICS Moderator
Joined: 14 Jan 2008 Posts: 2501 Location: Atlanta, Georgia, USA
|
|
|
|
There was a method to my madness regarding the length of an ITEM. You could define an array copybook -
Code: |
01 TSQ-COPYBOOK-REC.
03 TSQ-COPYBOOK-SUB PIC 9(04) COMP VALUE ZERO.
03 TSQ-COPYBOOK-SUB-MAX PIC 9(04) COMP VALUE ZERO.
03 TSQ-COPYBOOK-ITEM-NBR PIC 9(08) COMP VALUE ZERO.
03 TSQ-COPYBOOK-ARRAY-REC.
05 TSQ-COPYBOOK-ARRAY-ITEM OCCURS 655 TIMES PIC X(50).
DIVIDE LENGTH OF TSQ-COPYBOOK-ARRAY-REC BY LENGTH OF TSQ-COPYBOOK-ARRAY-ITEM (1)
GIVING TSQ-COPYBOOK-SUB-MAX.
|
As you add an item to the ARRAY-ITEM TABLE, you bump COPYBOOK-SUB by 1, providing that COPYBOOK-SUB-MAX has not been exceeded and you issue a WRITEQ or WRITEQ REWRITE. If COPYBOOK-SUB has exceeded COPYBOOK-SUB-MAX, then you're finished with that ITEM (let's say, number 1) and now you use the COPYBOOK to build ITEM number 2 and so on and so on.
Subsequently, you could wind up with the max of 32767 items/records which (in this example) are each 32758 bytes long (655 * 50) + 8.
Always define the TSQ-COPYBOOK-ITEM-NBR as a binary-fullword (as illustrated) so you can avoid all high-order truncation as you would with a binary-halfword, which could truncate (depending on the TRUNC option) when the value exceeds 9999.
However, you may not need the TSQ-ITEM-NBR but, I thought I'd throw it in for good measure.
HTH....
Bill |
|
Back to top |
|
|
|