# Download a Natural-ADABAS code in a text file

**URL:** <https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641>\
**Category:** Forum\
**Tags:** Adabas-Natural, Adabas, Adabas-on-Mainframes, Adabas-Utilities-on-Mainframes\
**Created:** [May 25, 2016, 11:37am UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641 "2016-05-25T11:37:24Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vijayendar\_Gururajan](https://avatars.discourse-cdn.com/v4/letter/v/838e76/32.png) [@Vijayendar\_Gururajan](https://techcommunity.softwareag.com/u/Vijayendar_Gururajan)\
**Post date:** [May 25, 2016, 11:37am UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/1 "2016-05-25T11:37:24Z")

</div>

Hi guys,

I am very new to the Natural-Adabas world and I have a requirement to download all the natural-adabas code from a specific library into a notepad. Is there a way to do this (like the OPTION 6 in the TSO) from the Natural menu?

I tried writing an emulator script which again dint work.

I tried googling on this, but was unable to find a way. Also tried searching the older posts but no luck. Sadly, there is no one is around. :shock:

Please help.

---

<div class="post-metadata">

**Author:** ![Steve\_Robinson](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/steve_robinson/32/107_2.png) [@Steve\_Robinson](https://techcommunity.softwareag.com/u/Steve_Robinson)\
**Post date:** [May 25, 2016, 1:02pm UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/2 "2016-05-25T13:02:05Z")

</div>

What is the purpose of this task?

If it is just to archive all the code, use SYSOBJH.

Is it possible, since no one is there, that you were given this assignment as a “fools errand”?

---

<div class="post-metadata">

**Author:** ![Vijayendar\_Gururajan](https://avatars.discourse-cdn.com/v4/letter/v/838e76/32.png) [@Vijayendar\_Gururajan](https://techcommunity.softwareag.com/u/Vijayendar_Gururajan)\
**Post date:** [May 25, 2016, 3:40pm UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/3 "2016-05-25T15:40:11Z")

</div>

Hi Steve, we need to feed them(codes in the notepad) to a software that checks for security compliance and this software is a non-mainframe one.

---

<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:** [May 25, 2016, 5:57pm UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/4 "2016-05-25T17:57:43Z")

</div>

As Steve said, use the SYSOBJH utility to unload the code to a flat file and then FTP it etc.

However, the code will be unloaded in an “internal” format so you would probably have to  
split it to get one file per module etc., but this will still leave you with incomplete code with  
references to copycodes, LDAs, PDAs etc.

---

<div class="post-metadata">

**Author:** ![Steve\_Robinson](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/steve_robinson/32/107_2.png) [@Steve\_Robinson](https://techcommunity.softwareag.com/u/Steve_Robinson)\
**Post date:** [May 25, 2016, 6:52pm UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/5 "2016-05-25T18:52:21Z")

</div>

I am rather doubtful that a software package that is not specific to Natural can assess security compliance of Natural code.  
In particular, are you familiar with Ampersand “variables” that allow one Natural program to effectively alter the functioning of another Natural program?  
Then, there are the varied means to pass data between Natural objects, including the Stack, which can also be used to alter the sequence of executed programs.  
Lets not forget MOVE INDEXED which could be used play all sorts of games.

To repeat my first sentence; if you are serious about security, a generic software package will not suffice.

---

<div class="post-metadata">

**Author:** ![Brian\_Johnson1](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/brian_johnson1/32/163_2.png) [@Brian\_Johnson1](https://techcommunity.softwareag.com/u/Brian_Johnson1)\
**Post date:** [May 25, 2016, 8:00pm UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/6 "2016-05-25T20:00:03Z")

</div>

I am curious what this “security compliance” software is going to look for, exactly.

---

<div class="post-metadata">

**Author:** ![Douglas\_Kelly](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/douglas_kelly/32/102_2.png) [@Douglas\_Kelly](https://techcommunity.softwareag.com/u/Douglas_Kelly)\
**Post date:** [May 26, 2016, 1:30am UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/7 "2016-05-26T01:30:48Z")

</div>

in any case…one option to look at is the “LIST” command - there are options there that might help

- LIST SEQ - lists selected programs - use selection like “list seq ab\*” or “list seq p ab\*” (list all programs starting with ab) or just “list seq \*” for everything 

- LIST SEQ EXPAND - lists programs selected (see above) and expands INCLUDE and USING data-area statements - e.g. “list seq \* expand”

Run these in batch and send the output to a sequential file or PDS to capture it, download it and feed into your magical security scanner.

---

<div class="post-metadata">

**Author:** ![Vijayendar\_Gururajan](https://avatars.discourse-cdn.com/v4/letter/v/838e76/32.png) [@Vijayendar\_Gururajan](https://techcommunity.softwareag.com/u/Vijayendar_Gururajan)\
**Post date:** [May 26, 2016, 10:44am UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/8 "2016-05-26T10:44:43Z")

</div>

@Steve: Very true, I had flagged this earlier but I was later told that this is being tested on a trial basis. And our’s is the only application that has Nat-Ada. :roll:

@Brian: It sort of checks for specific key-words and looks for fields that contain customer data patterns. But I am not sure on what all it can churn out. As a first step we wanted to feed some nat-ada code to it and see how well it works and a detailed feedback will be given on the areas that ran amuck.

Thanks Doug et all, LIST SEQ EXPAND command seem to work well. The magical scanner should now feel very happy. 🙂

Cheers!

---

<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:36pm UTC](https://techcommunity.softwareag.com/t/download-a-natural-adabas-code-in-a-text-file/188641/9 "2021-04-02T15:36:06Z")

</div>

Closed on April 2, 2021, 3:36pm UTC


