# CLOSE VSAM file in NATURAL

**URL:** <https://techcommunity.softwareag.com/t/close-vsam-file-in-natural/172964>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-on-Mainframes, Natural-Database-and-TP-Monitor-Interfaces-on-Mainframes\
**Created:** [October 11, 2013, 2:36am UTC](https://techcommunity.softwareag.com/t/close-vsam-file-in-natural/172964 "2013-10-11T02:36:17Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eugene](https://avatars.discourse-cdn.com/v4/letter/e/8797f3/32.png) [@Eugene](https://techcommunity.softwareag.com/u/Eugene)\
**Post date:** [October 11, 2013, 2:36am UTC](https://techcommunity.softwareag.com/t/close-vsam-file-in-natural/172964/1 "2013-10-11T02:36:17Z")

</div>

We would like to be able to dynamically close a VSAM file in a Batch NATURAL Session (Mainframe VSE).  
We are running NATURAL RPC Server and need to close otherwise we have to terminate RPC server to free up VSAM files for other jobs/utilities. There is sufficient documentation on how to OPEN a VSAM file but I can find nothing about how to CLOSE it.

---

<div class="post-metadata">

**Author:** ![Eugene](https://avatars.discourse-cdn.com/v4/letter/e/8797f3/32.png) [@Eugene](https://techcommunity.softwareag.com/u/Eugene)\
**Post date:** [November 4, 2013, 8:09pm UTC](https://techcommunity.softwareag.com/t/close-vsam-file-in-natural/172964/2 "2013-11-04T20:09:18Z")

</div>

We considered writing an assembler program to close the file given a DDNAME, however that would not release the buffers NATURAL has allocated in VSIZE, so a USR routine from Software AG would be very nice???

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:29pm UTC](https://techcommunity.softwareag.com/t/close-vsam-file-in-natural/172964/3 "2021-04-02T15:29:37Z")

</div>


