# Help to find a character string

**URL:** <https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-on-Mainframes, Natural-on-Windows-Unix\
**Created:** [June 18, 2008, 12:47am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348 "2008-06-18T00:47:02Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![RESTETS1](https://avatars.discourse-cdn.com/v4/letter/r/76d3ee/32.png) [@RESTETS1](https://techcommunity.softwareag.com/u/RESTETS1)\
**Post date:** [June 18, 2008, 12:47am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/1 "2008-06-18T00:47:02Z")

</div>

I am not a Natural programmer and we are using an unsupported version of the product. I need to be able to scan our Natural VSAM file to see if there are any references to a given character string. In this case the string is T1000ME. This is actually a CICS file name. I’m trying to find out if there are any programs that use the dataset associated with this file name. I have no idea of what libraries are defined or any other information. I would need to find which libraries I can scan and scan each/all of them.  
Is there a command or series of commands which I can use to see if this character string is used anywhere?  
Thanks for any assistance anyone can provide on this matter.

---

<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:** [June 18, 2008, 8:45am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/2 "2008-06-18T08:45:20Z")

</div>

check out the SCAN command.

If you have Natural Security (LOGON SYSSEC, MENU), then you can find out what libraries you have defined. If not, you can use SYSMAIN to search your system file.

---

<div class="post-metadata">

**Author:** ![RESTETS1](https://avatars.discourse-cdn.com/v4/letter/r/76d3ee/32.png) [@RESTETS1](https://techcommunity.softwareag.com/u/RESTETS1)\
**Post date:** [June 19, 2008, 11:10pm UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/3 "2008-06-19T23:10:30Z")

</div>

Thanks for the response but…  
In my CICS region I typed the transid NATV which brings me to a splash screen which has the word NEXT in the upper left corner and LIB=SYSTEM in the upper right corner. I typed LOGON SYSSEC,MENU and pressed Enter. I then got a screen titled NATURAL LOGON PROCEDURE with the message “NO LOGON IS POSSIBLE TO LIBRARY SYSSEC”.

I pressed the Clear key and once again I’m at the screen with NEXT in the upper left corner and LIB=SYSTEM in the upper right corner. I then type SCAN on the top line and press the Enter key. I get a message "NAT0082 INVALID COMMAND OR PROGRAM DOES NOT EXIST IN LIBRARY. "

As I mentioned in the original post you can’t assume I know anything so any replies to my request need to be as detailed as possible.

---

<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:** [June 20, 2008, 2:22am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/4 "2008-06-20T02:22:45Z")

</div>

forums aren’t a great substitute for training.

SCAN is documented in the Natural documentation - check out the documentation links with the forum - [http://techcommunity.softwareag.com/ecosystem/documentation/natural/](http://techcommunity.softwareag.com/ecosystem/documentation/natural/)

---

<div class="post-metadata">

**Author:** ![RESTETS1](https://avatars.discourse-cdn.com/v4/letter/r/76d3ee/32.png) [@RESTETS1](https://techcommunity.softwareag.com/u/RESTETS1)\
**Post date:** [June 21, 2008, 12:34am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/5 "2008-06-21T00:34:35Z")

</div>

Forums are supposed to be where people who need help can ask for it and that’s what I’m doing.

We don’t have anyone who has any knowledge of the product here so I’m looking to the world at large for suggestions. Your reply was appreciated but our system is either so far out of date (version 1.2) or we’re missing something.

---

<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:** [June 21, 2008, 4:35pm UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/6 "2008-06-21T16:35:01Z")

</div>

Version 1.2 ??? WOW. This has to be a record. I understand you are not a Natural person, so some history might be of interest. Version 2.1 arrived on the scene in either 1984 or 1985. The applications you have, and the software that is running them, are over twenty years old.

You should either get someone inhouse who knows about Adabas/Natural, or should look to get off the platform. This is not intended to be derogatory in any way. Simply a reflection of what appears to be an all but untenable situation. What do you do if someone wants to change functionality? Or add an enhancement?

steve

---

<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:** [June 23, 2008, 12:29pm UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/7 "2008-06-23T12:29:55Z")

</div>

ok…to get back to the original question, given that you are on v1.2…

You will need a competent Natural programmer who can write “reporting mode” Natural programs. You need a program that will read the Natural system file to scan for the strings you are looking for. As v1.2 is not accessible to those of us on the forums, we can’t provide a working program: I don’t know which of system file layout decription you might have (a “DDM” - data definition module), nor can I test anything without access to a v1.2 environment. As the language has evolved in the past 20+ years, I don’t know that a program I could write now would compile or run in v1.2.

With that old of a version, we can’t possibly give you detailed answers on how to do anything. As evidenced by my suggestion to use the SCAN command, which wasn’t implemented then.

---

<div class="post-metadata">

**Author:** ![RESTETS1](https://avatars.discourse-cdn.com/v4/letter/r/76d3ee/32.png) [@RESTETS1](https://techcommunity.softwareag.com/u/RESTETS1)\
**Post date:** [June 23, 2008, 7:06pm UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/8 "2008-06-23T19:06:59Z")

</div>

There is no one in house who is conversant in the language. That’s why I was looking for help from the outside.

I appreciate everyones surprise at the level we are running and also am grateful for all of the replies you’ve given me. I guess I’ll just have to forget about figuring this out. It’s more of a curiosity than a problem.

Thanks to all.

---

<div class="post-metadata">

**Author:** ![john\_db](https://avatars.discourse-cdn.com/v4/letter/j/f04885/32.png) [@john\_db](https://techcommunity.softwareag.com/u/john_db)\
**Post date:** [July 7, 2008, 7:55am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/9 "2008-07-07T07:55:33Z")

</div>

Hello

Is it possible to scan for linefeed and/or carriage return (LF/CR)? We have the contents of a Windows text file passed to a dynamic variable in nat414 and it would be handy to split it into records

Thanks

---

<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:** [July 7, 2008, 10:56am UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/10 "2008-07-07T10:56:42Z")

</div>

maybe you could open a new topic since your question doesn’t sound much like a Natural 1.2 problem that RESETS had.

When you do, please do clarify: are you passing the name of a file to a variable (from where?) or the contents of a file to a variable. There are lots of possibilities…SEPARATE statement pops to mind; setting the DEFINE WORK FILE options correctly could also solve your problem without resorting to scanning.

---

<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:50pm UTC](https://techcommunity.softwareag.com/t/help-to-find-a-character-string/78348/11 "2021-04-02T14:50:31Z")

</div>


