IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Is there a way to close VSAM files used by CICS via ISPF


IBM Mainframe Forums -> CICS
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Sat Feb 04, 2023 11:19 am
Reply with quote

Is there a way to close VSAM files used by CICS via ISPF without logging into CICS region and doing "CEMT I FIL(filename)" and then close it ?
Back to top
View user's profile Send private message
Joerg.Findeisen

Senior Member


Joined: 15 Aug 2015
Posts: 1255
Location: Bamberg, Germany

PostPosted: Sat Feb 04, 2023 12:25 pm
Reply with quote

See if IDCAMS VERIFY is of help for you.
Back to top
View user's profile Send private message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Sat Feb 04, 2023 3:57 pm
Reply with quote

I tried closing the VSAM file that is opened in CICS by issuing the IDCAMS VERIFY command. But it failed with below error

Error Opening filename1
** VSAM OPEN RETURN CODE IS 168 **
Function Terminated. Condition Code is 12
IDCAMS Processing complete. Maximum Condition Code was 12.

The VSAM return code 168 means that the files are in use.
Back to top
View user's profile Send private message
Rohit Umarjikar

Global Moderator


Joined: 21 Sep 2010
Posts: 3053
Location: NYC,USA

PostPosted: Mon Feb 06, 2023 8:58 pm
Reply with quote

Please talk to CICS support team if they have any utilities/product that your site purchased. We use IPCPBTCH / CAFC utility.

if nothing then try programmatically.
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Tue Feb 07, 2023 1:40 pm
Reply with quote

Try issuing a console command e.g. F region-name,CEMT S FIL(filename) CLO DIS . This can be done from e.g. SDSF if your site allows it.

It's usually a good idea to also disable the file when closing as otherwise it may get opened when referenced by a CICS task.

Garry.
Back to top
View user's profile Send private message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Tue Feb 07, 2023 4:27 pm
Reply with quote

I tried this under =6 (ISPF Command Shell)

F regionname,CEMT S FIL(filename) CLO DIS

but getting below error.

SYMBOLIC PARMS IN VALUE LIST IGNORED -
COMMAND PROCEDURE HAS NO PROC STMT
Command rejected - 'LOGOFF ' command not supported under ISPF.
ISPD226 Invalid command - Commands such a LOGON, LOGOFF, SPF, ISPF, etc. are not permitted.
Back to top
View user's profile Send private message
Joerg.Findeisen

Senior Member


Joined: 15 Aug 2015
Posts: 1255
Location: Bamberg, Germany

PostPosted: Tue Feb 07, 2023 5:25 pm
Reply with quote

See what Garry has written:

This can be done from e.g. SDSF if your site allows it.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Tue Feb 07, 2023 8:21 pm
Reply with quote

Quote:
F regionname,CEMT S FIL(filename) CLO DIS
This is a console command and as such CANNOT be executed in ISPF. You may be able to execute it in SDSF (with authorization) but not in ISPF option 6. If you have authorization, you can enter it as a JCL statement and submit the job.
Back to top
View user's profile Send private message
Chetan Kumar

New User


Joined: 03 Dec 2012
Posts: 46
Location: India

PostPosted: Thu Feb 09, 2023 8:56 pm
Reply with quote

Below command works in console.

F regionname,CEMT S FIL(filename) CLO DIS

but it is as good as closing it using CEMT command in console. But I couldn't do it via ISPF or TSO.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CICS

 


Similar Topics
Topic Forum Replies
No new posts Compare 2 files and retrive records f... DFSORT/ICETOOL 3
No new posts Compare 2 files(F1 & F2) and writ... JCL & VSAM 8
No new posts Using API Gateway from CICS program CICS 0
No new posts Write line by line from two files DFSORT/ICETOOL 7
No new posts Access to non cataloged VSAM file JCL & VSAM 18
Search our Forums:

Back to Top