MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

ENQ in CICS and What Does It Do?

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware
View previous topic :: View next topic  
Author Message
deepa12
Beginner


Joined: 05 Apr 2005
Posts: 131
Topics: 64
Location: chennai

PostPosted: Thu Jul 31, 2014 5:59 am    Post subject: ENQ in CICS and What Does It Do? Reply with quote

There is an existing code as follows
There is a AZFILE;LK-FILE-KEY has the contents of 1 of the AZFILEKEY and its a partial key. Say there are 15 records
Code:

 EXEC CICS ENQ                     
      NOSUSPEND                   
      RESOURCE (LK-FILE-KEY)       
      LENGTH (33)                 
      NOHANDLE

I understand that this is for resource serialisation. Where this lock will be tracked
After the above:
I update 1 of the record occurrence of this key say 11th
now i start browsing from the 1st occurrence actually the update is not available i.e is not reflecting in the records read until i issue a syncpoint
Is it that once i do any enq after that any updates to any file will not be commited & available to the program until the deq is done?
_________________
deepa
Back to top
View user's profile Send private message Send e-mail
kolusu
Site Admin
Site Admin


Joined: 26 Nov 2002
Posts: 12358
Topics: 75
Location: San Jose

PostPosted: Thu Jul 31, 2014 7:46 am    Post subject: Reply with quote

deepa12,

ENQ is basically getting an EXCLUSIVE CONTROL of the dataset. It is the same as coding DISP=OLD in your JCL. Once you get an exclusive control, every body else who wants to access the dataset will have to wait.

It doesn't matter whether you update or just read the dataset once you get the ENQ.

SYNCPOINT is just committing the updates you made. That allows you to see the updates you made.

Unless you issue a DEQ , no one else can see the updates.

I don't remember the exact table that cics stores but you can get the list of ENQ using CEMT INQUIRE UOWENQ
_________________
Kolusu - DFSORT Development Team (IBM)
DFSORT is on the Web at:
www.ibm.com/storage/dfsort

www.linkedin.com/in/kolusu
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> CICS and Middleware All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group