# Handling NATERROR 3113

**URL:** <https://techcommunity.softwareag.com/t/handling-naterror-3113/92135>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-on-Mainframes\
**Created:** [November 17, 2009, 10:39pm UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135 "2009-11-17T22:39:51Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ashok5](https://avatars.discourse-cdn.com/v4/letter/a/b487fb/32.png) [@Ashok5](https://techcommunity.softwareag.com/u/Ashok5)\
**Post date:** [November 17, 2009, 10:39pm UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135/1 "2009-11-17T22:39:51Z")

</div>

I have a work file contains a list of ISN’s , The list has some deleted ISN’s from the ADABAS file. the requirement is to Read the workfile and use GET statement with the ISN and update a field on ADABAS file hence this the program should get the valid ISN’s and invalid ISN’s should be ignored. I tried using ON ERROR for handling NAT 3113 in the natural program but still the program fails with NAT error 3113. Can anyone give me an idea on how to handle this error.

Thanks in Advance.

Regards,  
Ashok.

---

<div class="post-metadata">

**Author:** ![Ralph\_Zbrog](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/ralph_zbrog/32/78_2.png) [@Ralph\_Zbrog](https://techcommunity.softwareag.com/u/Ralph_Zbrog)\
**Post date:** [November 18, 2009, 12:02am UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135/2 "2009-11-18T00:02:51Z")

</div>

I suggest you change your GET to

```auto
RD.                                
READ file BY ISN FROM #ISN THRU #ISN
  WRITE 'ISN' #ISN 'found'       
END-READ                           
IF *COUNTER (RD.) = 0             
  THEN                             
    WRITE 'ISN' #ISN 'not found'   
END-IF                             
```

It’s not as efficient as the GET, but allows you to trap the missing ISNs quite easily.

If you have access to NatParms, you could set RCGET to OFF, then code

```auto
G. GET file #ISN
IF *ISN (G.) = 0             
  THEN                             
    WRITE 'ISN' #ISN 'not found'
  ELSE
    ... process record ...
END-IF                             
```

---

<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:** [November 18, 2009, 12:08pm UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135/3 "2009-11-18T12:08:34Z")

</div>

Set the dynamic parameter RCGET=OFF for this Batch(?) job.  
This will “ignore” any NAT3113 errors in your session.  
.  
— Parameter Reference —  
RCGET - Handling of Response Code 113 for GET Statement  
This Natural profile parameter specifies the action to be taken if Adabas Response Code 113 (requested ISN not found) is returned during the execution of a GET statement.  
.  
Possible settings:  
ON Response Code 113 causes the program to be terminated.  
OFF Response Code 113 will be ignored, the system variable \*ISN will be set to “0”, and processing will continue.  
Default setting - ON  
Dynamic specification - yes  
Specification within session - no

---

<div class="post-metadata">

**Author:** ![Ashok5](https://avatars.discourse-cdn.com/v4/letter/a/b487fb/32.png) [@Ashok5](https://techcommunity.softwareag.com/u/Ashok5)\
**Post date:** [November 18, 2009, 10:34pm UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135/4 "2009-11-18T22:34:59Z")

</div>

Thank you Ralph and Peter for your valuable information. I am not given access to set RCGET parameter. i have done my work with READ ISN logic.

---

<div class="post-metadata">

**Author:** ![Matthias1](https://avatars.discourse-cdn.com/v4/letter/m/9fc348/32.png) [@Matthias1](https://techcommunity.softwareag.com/u/Matthias1)\
**Post date:** [November 19, 2009, 12:35pm UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135/5 "2009-11-19T12:35:46Z")

</div>

I got a similar problem some months ago and solved it using a subprogram with an own on-error-routine. The main program looks like this:

```auto
...
READ WORK 30 #isn
  CALLNAT 'SUBPROGN' #isn
END-WORK
```

The Subprogram:

```auto
ON ERROR
IF *ERROR-NR = 3113
  ESCAPE MODULE
END-IF
END-ERROR

GET MYFILE #ISN
...
```

---

<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, 2:57pm UTC](https://techcommunity.softwareag.com/t/handling-naterror-3113/92135/6 "2021-04-02T14:57:46Z")

</div>


