Browse Prior Art Database

Merge System Using Direct-Access Storage Devices

IP.com Disclosure Number: IPCOM000047741D
Original Publication Date: 1983-Dec-01
Included in the Prior Art Database: 2005-Feb-08
Document File: 3 page(s) / 55K

Publishing Venue

IBM

Related People

Warren, WR: AUTHOR

Abstract

Records are merged during the merge phase of a sort merge process. Main storage is organized into buffers of a size equal to blocks of records on external storage. A block is read into an input buffer, the records in the block are merged with previously merged records without moving the records from their input buffer, merged records are rearranged so that records ready for output are collected in an output buffer, and that output buffer is written to external storage. The output buffer is then used as the input for a next block from external storage. According to this technique, during a preliminary string generation step or prior merge pass, records have been written in blocks on an external storage device.

This text was extracted from a PDF file.
At least one non-text object (such as an image or picture) has been suppressed.
This is the abbreviated version, containing approximately 52% of the total text.

Page 1 of 3

Merge System Using Direct-Access Storage Devices

Records are merged during the merge phase of a sort merge process. Main storage is organized into buffers of a size equal to blocks of records on external storage. A block is read into an input buffer, the records in the block are merged with previously merged records without moving the records from their input buffer, merged records are rearranged so that records ready for output are collected in an output buffer, and that output buffer is written to external storage. The output buffer is then used as the input for a next block from external storage. According to this technique, during a preliminary string generation step or prior merge pass, records have been written in blocks on an external storage device. During the merge phase, a plurality of blocks, at least one from each string being merged, are read into main storage buffers, each buffer being equal in size to a block, to form a longer string for output. The merge process is as follows: 1. With three or more buffers available in main storage, blocks read from external storage into all but one of the buffers. As the blocks are read, a merge list or chain is formed, showing the merged sequence of the records. The merge list is maintained in an area separate from the buffers, with each entry in the merge list identifying a record in a buffer and its position in the chain. 2. The next block is read into an available buffer. 3. The records in the last buffer are merged by placing them in the chain or merge list. This is done without moving records out of their input buffer by inserting entries into the merge list. 4. The merged records are rearranged so as to collect in an output buffer the next records to be output. This is done by moving records directly from their original input buffers into a buffer that will be will be used for output. (This buffer, being prepared for output, is different than the buffer last used for input during step 2.) 5. The buffer prepared for output during step 4 is written out to external storage. 6. Steps 2 through 5 are repeated until all records ha...