Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

To find the number of records in TSQ.

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS
View previous topic :: :: View next topic  
Author Message
Kanagaraj

New User


Joined: 20 Jan 2006
Posts: 3
Location: Shanghai

PostPosted: Mon Jun 12, 2006 7:44 am    Post subject: To find the number of records in TSQ.
Reply with quote

Is that any way or CICS command to find out the Number of records in particular TSQ?s.

Since some other programs are adding the records into TSQ. From my program I have find out number of records in that TSQ before I start processing.

Kindly come help me on this?

Thanks in advance.
icon_question.gif
Back to top
View user's profile Send private message

gsnvsr

New User


Joined: 06 Jul 2005
Posts: 40

PostPosted: Tue Jun 13, 2006 9:47 pm    Post subject: Re: To find the number of records in TSQ.
Reply with quote

Kanagaraj wrote:
Is that any way or CICS command to find out the Number of records in particular TSQ?s.

Since some other programs are adding the records into TSQ. From my program I have find out number of records in that TSQ before I start processing.

Kindly come help me on this?

Thanks in advance.
icon_question.gif


You could perhaps use the "NUMITEMS" parameter when you initially read the TSQ. This will return the number of items in the TSQ. Define a binary halfword in the working storage to be used with NUMITEMS. Hope this helps!

Best regards, Prasad
Back to top
View user's profile Send private message
Kanagaraj

New User


Joined: 20 Jan 2006
Posts: 3
Location: Shanghai

PostPosted: Thu Jun 15, 2006 11:13 am    Post subject: Re: To find the number of records in TSQ.
Reply with quote

gsnvsr wrote:
Kanagaraj wrote:
Is that any way or CICS command to find out the Number of records in particular TSQ?s.

Since some other programs are adding the records into TSQ. From my program I have find out number of records in that TSQ before I start processing.

Kindly come help me on this?

Thanks in advance.
icon_question.gif


You could perhaps use the "NUMITEMS" parameter when you initially read the TSQ. This will return the number of items in the TSQ. Define a binary halfword in the working storage to be used with NUMITEMS. Hope this helps!

Best regards, Prasad


I have coded like below in my program,
WS-TSQ-CNTOL PIC 9(04) COMP.

EXEC CICS READQ TS
QNAME (WS-USER-TSQ-NAME)
INTO (WS-TSQ-RECORD)
LENGTH (WS-TSQ-LENGTH)
ITEM (WS-TSQ-ITEM)
NUMITEMS(WS-TSQ-CNTOL)
RESP (CICS-RESP-CODE)
END-EXEC.

I can able get the number records(items) in the TSQ while reading the first record itself.

Prasad, Thanks for your valuable reply.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Check if any Detail records and extra... V S Amarendra Reddy SYNCSORT 19 Mon May 08, 2017 8:54 pm
No new posts find RACF group for access to spooled... jzhardy JCL & VSAM 1 Mon May 08, 2017 11:46 am
No new posts SMTP the current generation number of... Jyothi Kulunde JCL & VSAM 4 Thu May 04, 2017 4:08 pm
No new posts To find out size allocated to a seque... ashek15 JCL & VSAM 15 Thu Apr 27, 2017 9:42 am
No new posts Edit large number of datasets (QSAM) zh_lad TSO/ISPF 3 Tue Apr 04, 2017 6:08 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us