;
                                                
                             ---  Z B I B  ---  
                                                
         Version 1.0 -- A ZCPR3 Bibliography Database File Manager

                           I -->  Installation 
                           D -->  Description  
                           U -->  Use          
                           A -->    Add        
                           L -->    Delete     
                           E -->    Edit       
                           F -->    Find       
                           B -->    Browsing   
                           O -->    Output     
                           P -->  Patching     
                           X -->  Index        
                           S -->  Sorting      
                           Y -->  Miscellany   
:I

 Installation 

If you're running ZCPR3.3+, ZBIB needs no ZCPR3 installation, but if you're 
running ZCPR3.0, you need to install ZBIB in your usual way.

Before using ZBIB you will need to run ZCNFG with ZBIB.CFG to set certain 
defaults and printer codes.
:D

 Description - 1/2 

ZBIB is the Z-System Bibliography file manager.  Professional librarians 
have helped design the screen format and fields to make the program as 
immediately useful as possible for researchers and writers.
  
ZBIB is derived from ZDB and shares most its features:  compact size, 
speed, use of extended TCAP, use of internal clock, and editing and search 
routines.  ZBIB will search for any string (or part thereof) in any field.  
An express search for last name or author uses an in-RAM index of pointers 
for blazing speed.  You may also write the records to a new file in the 
sorted order of the current index, removing deleted records in the process. 
The old file is renamed and retained as a backup.  The new file is 
automatically reopened after the sort is done and the first record 
displayed just as on startup.  Output options include file card printing 
and the writing of either a comma-delimited format ASCII file for use with 
WordStar's MergePrint or a WordStar compatible text file which can then be 
edited and formatted to the user's taste.  File card printing and CDF and 
WordStar file options allow the selection of any one of four keys for the 
output.

 Description - 2/2 

ZBIB takes advantage of many Z-System features.  If you lack a clock, ZBIB 
allows for manual entry of the date.  ZBIB does not require an RCP or FCP 
or IOP to work.  It can use the extended TCAP with the 13 graphics 
characters introduced in VLIB4D.

ZBIB's data file uses a 512 byte record so that each one is on a page 
boundary.  There is no header to the file.  File size is limited to a mere 
64K 512 byte records -- due to the use of 16 bit counters for the number of 
records and the file pointer.  Disk capacity is the real world limiter on 
file size.  On a 390K floppy, ZBIB itself will take 8K.  Divide the 
remaining 382K by 2 (you need twice the space in order to do a sort) to get 
maximum file size -- in this case 382 records of 256 bytes.  On a hard 
disk, of course, you hardly need to worry about file size.

The index requires 16 bytes per record plus an order table equal to the 
number of records in the data file.  Writing the CDF ASCII file or the 
WordStar file requires a 16K buffer above the index and order table.  A 
system with 45K or more of TPA should handle a ZBIB file of 1400 records 
without overwriting the CCP.  ZBIB has a built-in memory check to prevent 
crashes with very large files.
:U

 Use 

Entering 'ZBIB /<cr>' at the command line will produce a help message.  If 
you also enter a data file name, ZBIB will look for it, create it if it does 
not exist, and display either a blank record (if it's a new file) or the 
first non-erased one in the file.  If no file name is specified, ZBIB will 
use ZBIB.DTA as the default data file name.

If you don't have an internal clock (or have a clock module loaded), ZBIB 
will ask for the current date.  If you wish to quit at this point, enter ^C 
at any time while entering the date.

The menu of ZBIB commands is displayed in a single menu line at the bottom 
of the screen.
:A

 Add - 1/2 

'A' for Add is the command used to enter new records.  The display is 
cleared and the cursor placed in the first field ready for your entry.  
Each field is marked off with angle brackets -- >           < -- so you 
know how much space you have.  If you try to enter more characters than 
allowed in any field, you will get beeped at, but you can back up and fix 
things.   The editing and cursor movement keys are:
     
     ^X, TAB, RETURN or down arrow moves to the next field.
     ^E or up arrow moves to the previous field.
     ^S/^D or left arrow/right arrow move cursor left/right.
     ^A/^F move cursor one word left/right.  
     ^G deletes the character at the cursor and moves the remainder of 
          the line one character left.  
     ^T deletes the word to the right of the cursor.
     ^Y deletes from cursor position to the end of line.  
     ^V toggles the character insert mode, allowing you to insert 
          characters at the current cursor position, shifting the 
          rest of the line to the right.
     ESC or ^W at any point to finish the entry.
     ^Q at any point aborts the editing.

 Add - 2/2 

If you go past the first or last field, you are given a choice of redoing 
the entry to correct any mistakes or omissions or saving.  Press ESC or ^W 
at any point to finish the entry.  Entering ^Q at any point will abort the 
entry without saving the results.  ZBIB intercepts U/D/R/L terminal arrow 
keys and interprets them properly.  The editing keys and prompts are 
displayed at the bottom of the screen.  On completion of a new entry you 
are given the option of continuing to add new records or quitting.  When 
you finish entering new records, the index will automatically be sorted.

If you wish to ensure that a header record that describes the data file is 
always displayed as the first record when the file is sorted on either 
index, enter several spaces as the initial author's last and first name 
characters and make sure the title field has no entry.
:L

 Delete 

Pressing 'D' lets you delete a record from the file.  You are given a 
chance to say no if you mistakenly press the 'D'.  The record is filled 
with nulls except for the first byte which is 0FFH, marking it as a deleted 
record.  Deleted records are dropped from the new file when a new sorted 
file is written.  Deleting a record does not change the record count in the 
header line of the screen since the deleted record is still in the file 
until a new sorted file is written.  Deleted records are not displayed or 
printed.
:E

 Edit 

'E' for Edit works exactly like Add except that it is for updating existing 
information.  You cannot edit the date.  It is changed automatically.  As 
in Add, ESC or ^W exits the editing session and saves the edited record and 
^Q aborts the editing session and restores the unedited record.
:F

 Find - 1/2 

There are two search routines in ZBIB.  'X' (Express) Find searches the 
index in memory for a match.  Because the index is in memory, the Express 
search is very fast.  When the index is sorted by the author's last and 
first names, each index record is made up of the first 6 characters of the 
last name, the first 3 characters of the first name, and the first 5 
characters of the title.  When the index is sorted by title, each record 
contains 9 characters from the title field and the first 5 characters of
the author's last name.  Leading "A", "An", and "The" are disregarded in 
indexing the title to maintain proper alphabetic order.

The other search works on any field but is slower, as it must read each 
record and search it for a match.  Press 'F' for this one.

 Find - 2/2 

You may enter up to ten characters in the search string.  Find is not case 
sensitive and partial strings are fine.  Entering "jo" to search for 
"Jones" will get the job done.  You can enter more than one word, e.g., 
"St. Paul," as long as they are in the same field.  If the search string is 
found in any field of any record, that record will be displayed on the 
screen.  You may then opt to end the search or continue it.  If there's no 
match, ZBIB tells you so.  Even in fairly large files, Find works quickly, 
but Express Find is much faster.  Express Search and Find are also 
available under the Output routine.
:B

 Browsing 

Previous and Next are for browsing through the file.  Pressing '<', or ',' 
both work for Previous and '>', or '.' both work for Next.  Records are 
displayed in sorted index order, so if the file is not in sorted order, the 
record numbers appearing in the header line may not be in sequential order.  
Records are displayed in a circular wrap-around manner.  If you are going 
backwards through the file and reach the first record, another Previous 
command will go to the end of the file.  "Next" acts in a similar fashion 
when it reaches the end of the file.  Two other commands, not on the menu, 
are 'T' (Top) and 'B' (Bottom).  They quickly take you to the first or last 
record in the file.
:O

 Output -1/2 

Output has submenus offering a choice of printing file cards or producing 
either a comma-delimited format ASCII datafile or a WordStar compatible 
text file.  The file card option gives the further choice of printing a 
single label, those which match a key, multiple copies, or the entire file. 
You can also use Find, Xfind, or Next before issuing the print command.

When you select 'Key', you will be asked to select the author's last name, 
title (both lines), periodical title, or notes (both lines) fields for 
matching the specified key.  If you select 'X', the search for a match will 
cover both note lines in their entirety.  If you want to make file cards 
for a special topic, the topic names can be put on the notes lines.  Only 
the records with the topic word present will be printed.  There's room for 
lots of imagination in the use of this feature to create special 
bibliographies.


 Output -2/2 

The CDF and WordStar options offer a choice of writing the entire file 
(choose 'All' at the menu) or selected records (choose 'K' at menu) and 
pick the key to use.

Printing of file cards (and writing of the CDF or WordStar files) is done 
in sorted index order.   Printer escape codes are near the beginning of 
ZBIB and may be configured as the user wishes with ZCNFG and ZBIB.CFG.

The CDF and WordStar file routines use a large output buffer and do the job 
very quickly.  The resulting files are in the currently logged directory.  
Both files can be edited with WordStar, ZDE, or any other word processor.
:P

 Patching 

ZBIB has a number of locations near the beginning of the program that can be 
patched using ZP, ZPATCH, DDT, etc, to alter the operation of the program 
to suit the user, although ZBIB.CFG file is supplied for use with ZCNFG.COM 
to make the job easier.
:X

 Index 

The Index command allows you to specify the field to use to make up the 
index.  The index is automatically maintained in sorted order and 
determines the order in which the records are displayed or printed.  The 
index display informs you of the current index type.  The Author index 
key produces an index record for each file record consisting of the first 
6 characters of the last name, the first 3 characters of the first name, 
and the first five characters of the title.  The Title index key produces 
index records consisting of the first 9 Title characters and the first 5 
characters of the authors's last name.  Since you always have at least the 
initial 5 last name characters, Express Finds using up to the first 5 last 
name characters will work no matter which index is currently in use.
:S

 Sort 

The Sort command (^S) writes a new file in the current directory with the 
original data file name having its records in the order of the current 
sorted index.  The old file is retained as a backup with the name 
ZBIBBAK.DTA.  If a previous ZBIBBAK.DTA file is present, it is deleted.  
Deleted records are purged when Sort writes a new file.
:Y

 Miscellaneous 

ZBIB's data file uses a 512 byte record so that each one is on a page 
boundary.  Disk capacity is one limiter on file size.  On a 390K floppy, 
ZBIB itself will take 8K.  Divide the remaining 382K by 2 (you need twice 
the space in order to do a sort) to get maximum file size -- in this case 
382 records of 512 bytes.  On a hard disk, of course, you hardly need to 
worry about file size.

The other limiter on file size is RAM.  The index requires 16 bytes per 
record plus 2 bytes per record for an order table.  Writing the CDF ASCII 
file requires a 16K buffer above the index and order table.  A system with 
50K or more of TPA can handle a ZBIB file of 1400 records without over- 
writing the CCP.  If you never need a CDF file, you can handle a much 
larger file, as much as 2400 records, depending on your TPA.  Very large 
files take time for ZBIB to read through, index, and sort on startup, a 
minute or longer.  Writing a new, sorted file takes about 1 minute per 100 
records on a hard disk drive system, longer on floppies.  If you have very 
large files, it may make sense to break them into smaller units for easier 
handling by ZBIB.  ZBIB does a check of available memory before adding a 
new record or writing a CDF file and aborts if there's not enough RAM.

Sometimes the screen display may get out of whack.  The main menu has an 
undisplayed command -- ^R (Control-R) -- which refreshes the screen 
display.
