| IBM MAINFRAME HELP & SUPPORT FORUMS Technical Forums for IBM Mainframe Applications like COBOL, JCL, CICS, DB2, FileAid, DFSORT, Endevor, Xpediter, CoolGen, CA-7&11, AbendAid, IMS, IDMS, PL/I, MqSeries, SyncSort, Assembler, ChangeMan, Easytrieve, InterTest, REXX, CLIST etc...
|
| View previous topic :: View next topic |
| Author |
Message |
monasu1998
Joined: 23 Dec 2005
Posts: 96
Location: Hyderabad
|
| Posted: Fri Dec 23, 2005 5:24 pm Post subject: Why shoud we use READ LOGICAL instead of FIND? |
|
|
Hi Frens:
Both the READ LOGICAL and FIND are useful in someway or other way.
But my DBA told me to use READ LOGICAL instead of FIND?
Can anyone plz clarify the significance of this instruction? |
|
| Back to top |
|
Dariusz
Joined: 11 Aug 2005
Posts: 27
Location: POLAND
|
| Posted: Fri Dec 23, 2005 5:42 pm Post subject: FIND when possible only ! |
|
|
Hi.
Find is more usable bycause it runs by ADABAS and it is quickly.
There is one problem only:
for FIND WITH .... we need descriptor field,but too much descriptors
is not better for quick working.
Regards. |
|
| Back to top |
|
toughmetals
Joined: 10 Jan 2006
Posts: 14
Location: India
|
| Posted: Mon Jan 16, 2006 12:30 pm Post subject: |
|
|
Hi,
Their is quite difference in processing of READ and FIND.
FIND:
1. Search the inverted list for Descriptor value
2. Build a list of ISN with the matched value
3. Process the ISN thru address converter to fetch the physical record
4. Repeat 3. until ISN list exhaust
READ Logical:
1. Search the inverted list >= Descriptor value and get the ISN
2. Process the ISN and get the actual record
3. Repeat 2. until Inverted list exhaust or u'll get some escaping criteria.
You see, the difference lies here is building of ISN list in case of FIND in working storage. Which is overhead.
Next major difference is we use READ logical only in case we want to get the data sorted by some descriptor value. Whereas, FIND will give us the data in order ISN site in the inverted list. |
|
| Back to top |
|
Borebeat
Joined: 16 Jan 2006
Posts: 7
Location: Coimbatore
|
| Posted: Mon Jan 16, 2006 11:59 pm Post subject: Read and Find |
|
|
| Its better to think of READ as for SEQUENTIAL READ and FIND for RANDOM ACCESS. |
|
| Back to top |
|
toughmetals
Joined: 10 Jan 2006
Posts: 14
Location: India
|
| Posted: Tue Jan 17, 2006 9:29 am Post subject: |
|
|
Hi BB,
"FIND for RANDOM ACCESS". Could you pls give me some examples?
So that we will be more clear. |
|
| Back to top |
|
Borebeat
Joined: 16 Jan 2006
Posts: 7
Location: Coimbatore
|
| Posted: Tue Jan 17, 2006 11:33 pm Post subject: Re: Why shoud we use READ LOGICAL instead of FIND? |
|
|
FIND do not actually read the database; ISNs are read directly from the Associator's inverted lists.
READ commands are used to read actual records from Data Storage. Depending on the specified command and its options, records are read individually
1. in the sequence in which they are stored; (READ PHYSICAL)
2. in the order of an ISN list created by one of the database query commands; or (READ BY ISN)
3. in logical sequence according to a user-specified descriptor. (READ LOGICAL)
FIND is faster than READ !!!! :-) |
|
| Back to top |
|
toughmetals
Joined: 10 Jan 2006
Posts: 14
Location: India
|
| Posted: Fri Jan 20, 2006 1:59 pm Post subject: |
|
|
Hi BB,
After Fetching ISN from the Inverted list it will go to Address converter to take the RABN number, after that it will get the actual record from DATABASE.
Only Histogram will not get into the DB and read the information only from Inverted List.
Thanks,
Deeps |
|
| Back to top |
|
| |
THIS IS AN ARCIVE FORUM IN READ ONLY MODE. IF YOU WANT TO ASK YOUR DOUBTS USE THE ACTUAL FORUM
|