Difference between find and read

Hi,

Just wanted to know the basic difference between a read operation and a find operation.
Again the find operation some times requires a level to operate better. But how does the level helps it and why do we use lebel

I hope I can build up my basics well fro here :smiley:

Thanks
Smruti Kanta

READ retrieves records in some sequence (user-defined key, ISN, or physical). FIND retrieves a collection of records and presents them in ISN sequence.

I hope I can build up my basics well fro here

Not nearly as well as by taking a Natural class, and, an Adabas class.

By “level” I presume you mean line or symbolic references. They are required occasionally by both FIND and READ to avoid ambiguity. For example, suppose I have a set of nested loops:

                     FIND ::::

                          FIND :::::
                              WRITE field-name
                          END-FIND

                      END-FIND

Inside the inner FIND, there are, at any time, two records available, one from the inner loop, one from the outer loop. Suppose “field-name” exists for both files (or views). How would Natural know which one you were referring to, unless you qualified the reference by a line number or symbol reference?

The difference between FIND and READ requires Adabas knowledge which I am guessing you do not have.

Very simplisticly, in a library, if you look up an authors name, and make a list of the books by an author (their dewey decimal number), then get the books one at a time, you are doing FIND logic.

By contrast, if you were to go to somewhere in the library and proceed to look at all the books in the library, you would be doing a READ PHYSICAL through the library.

This simplification does not begin to explain READ IN LOGICAL SEQUENCE, or READ BY ISN; but both of these require Adabas knowledge.

You will NOT learn Adabas or Natural by “playing” this way.

steve