11.1Spgoyette# $NetBSD: README,v 1.1 2011/01/07 15:05:58 pgoyette Exp $ 21.1Spgoyette# @(#)README 8.8 (Berkeley) 7/31/94 31.1Spgoyette 41.1SpgoyetteFairly large files (the command files) are built in this directory during 51.1Spgoyettethe test runs, and even larger files (the database files) are created in 61.1Spgoyette"/var/tmp". If the latter directory doesn't exist, set the environmental 71.1Spgoyettevariable TMPDIR to a directory where the files can be built. 81.1Spgoyette 91.1Spgoyette=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= 101.1SpgoyetteThe script file consists of lines with an initial character which is 111.1Spgoyettethe command for that line, or an initial character indicating a key 121.1Spgoyetteor data entry for a previous command. 131.1Spgoyette 141.1SpgoyetteLegal command characters are as follows: 151.1Spgoyette 161.1Spgoyettec: compare a record 171.1Spgoyette + must be followed by [kK][dD]; the data value in the database 181.1Spgoyette associated with the specified key is compared to the specified 191.1Spgoyette data value. 201.1Spgoyettee: echo a string 211.1Spgoyette + writes out the rest of the line into the output file; if the 221.1Spgoyette last character is not a carriage-return, a newline is appended. 231.1Spgoyettef: set the flags for the next command 241.1Spgoyette + no value zero's the flags 251.1Spgoyetteg: do a get command 261.1Spgoyette + must be followed by [kK] 271.1Spgoyette + writes out the retrieved data DBT. 281.1Spgoyetteo [r]: dump [reverse] 291.1Spgoyette + dump the database out, if 'r' is set, in reverse order. 301.1Spgoyettep: do a put command 311.1Spgoyette + must be followed by [kK][dD] 321.1Spgoyetter: do a del command 331.1Spgoyette + must be followed by [kK] unless R_CURSOR flag set. 341.1SpgoyetteS: sync the database 351.1Spgoyettes: do a seq command 361.1Spgoyette + must be followed by [kK] if R_CURSOR flag set. 371.1Spgoyette + writes out the retrieved data DBT. 381.1Spgoyette 391.1SpgoyetteLegal key/data characters are as follows: 401.1Spgoyette 411.1SpgoyetteD [file]: data file 421.1Spgoyette + set the current data value to the contents of the file 431.1Spgoyetted [data]: 441.1Spgoyette + set the current key value to the contents of the line. 451.1SpgoyetteK [file]: key file 461.1Spgoyette + set the current key value to the contents of the file 471.1Spgoyettek [data]: 481.1Spgoyette + set the current key value to the contents of the line. 491.1Spgoyette 501.1SpgoyetteBlank lines, lines with leading white space, and lines with leading 511.1Spgoyettehash marks (#) are ignored. 521.1Spgoyette 531.1SpgoyetteOptions to dbtest are as follows: 541.1Spgoyette 551.1Spgoyette -d: Set the DB_LOCK flag. 561.1Spgoyette -f: Use the file argument as the database file. 571.1Spgoyette -i: Use the rest of the argument to set elements in the info 581.1Spgoyette structure. If the type is btree, then "-i cachesize=10240" 591.1Spgoyette will set BTREEINFO.cachesize to 10240. 601.1Spgoyette -o: The rest of the argument is the output file instead of 611.1Spgoyette using stdout. 621.1Spgoyette -s: Don't delete the database file before opening it, i.e. 631.1Spgoyette use the database file from a previous run. 641.1Spgoyette 651.1SpgoyetteDbtest requires two arguments, the type of access "hash", "recno" 661.1Spgoyetteor "btree", and the script name or "-" to indicate stdin. 67