home *** CD-ROM | disk | FTP | other *** search
/ Eagles Nest BBS 8 / Eagles_Nest_Mac_Collection_Disc_8.TOAST / Developer Environments / TurPasDBTlbx / TP-Database Toolbox / Read.File < prev   
Encoding:
Text File  |  1987-12-11  |  9.6 KB  |  248 lines  |  [TEXT/TPAS]

  1.  
  2.                Welcome to Turbo Pascal Database Toolbox
  3.                ----------------------------------------
  4.  
  5.    This file contains information not found in the Owner's Handbook.
  6. It includes information on how to get technical support, corrections
  7. and omissions concerning the manual and files on the distribution disks.
  8. Since this information is very important to you, please read this file in
  9. its entirety.
  10.  
  11.  
  12.  
  13.  
  14. TABLE OF CONTENTS
  15. ------------------
  16.  
  17. 1. How to get Help
  18. 2. Combining High and Low Level Database routines
  19. 3. Configuring Turbo Access for HFS
  20. 4. Incompatible Unit Versions
  21. 5. Using Database Toolbox with MultiFinder 
  22. 6. Using the List Manager with the Database Toolbox
  23. 7. Files on the disk
  24.  
  25.  
  26. 1. HOW TO GET HELP
  27. ------------------
  28.   If you need help with Turbo Pascal Database Toolbox, read this 
  29.   file and the reference manual.
  30.  
  31.   If you still have a question and need technical assistance, help 
  32.   is available from the following sources:
  33.   
  34.   1. Type GO BORPRO on the CompuServe Information Service.
  35.   2. Check with your local software dealer or user group.
  36.   3. Write to: Borland International
  37.                Turbo Pascal Database Toolbox Technical Support
  38.                4585 Scotts Valley Drive
  39.                Scotts Valley, CA 95066
  40.   4. If you have an urgent problem that cannot wait, you can call 
  41.      the Borland Technical Support department. The phone number is
  42.      (408) 438-5300. 
  43.      
  44.   When calling or writing to technical support, you need to provide 
  45.   the following information:
  46.   
  47.      1. Product serial number. We will not be able to provide 
  48.         technical assistance without this.
  49.         
  50.      2. Product name and version number.  
  51.             
  52.      3. Macintosh Model and ROM type. Also, the brands and models of
  53.         any additional hardware.
  54.         
  55.      4. System and Finder version numbers (the Finder version number 
  56.         can be determined by looking in the Apple under About Finder...
  57.         from the desktop).
  58.  
  59.  
  60. 2. COMBINING HIGH AND LOW LEVEL DATABASE ROUTINES
  61. -------------------------------------------------
  62. The manual discusses two main types of database routines that you may
  63. call from your programs: the low level routines (found in TAccess.Unit),
  64. and the high level routines (found in TAHigh.Unit).  You can use both
  65. the high and the low level routines in a single program.  The sample
  66. program called HITADemo.pas in the Access Samples folder shows you
  67. how to accomplish this.  
  68.  
  69. In order to retrieve information from a dataset (initially created 
  70. with high level routines) with calls to low level routines, you will
  71. need to access the individual file types within a dataset, which are
  72. defined as below in TAHigh.Unit:
  73.  
  74. type 
  75.   DataSet = record
  76.                Data : DataFile;
  77.                Index : IndexFile;
  78.             end;
  79.             
  80. While this type is transparent to the programmer for all of the
  81. calls to the high-level routines, you will have to use it for such
  82. low-level routines as GetRec, FindKey, SearchKey, UsedRecs, FileLen,
  83. etc.  An example of this is given in the procedure below:
  84.  
  85.      Procedure TASize ( MyDataSet : DataSet;
  86.                         Var TotalRecords, UsedRecords: LongInt );
  87.      Begin
  88.        TotalRecords :=  FileLen (MyDataSet.Data);
  89.        UsedRecords  :=  UsedRecs (MyDataSet.Data);
  90.      End;  { TASize }
  91.      
  92.             
  93. Another example of how to access these two file types within a 
  94. dataset is given in the RebuildDatabase procedure in HITADemo.pas.
  95.  
  96.  
  97.  
  98. 3. CONFIGURING TURBO ACCESS FOR HFS
  99. -----------------------------------
  100.  
  101. The Turbo Pascal Database Toolbox manual recommends that you copy 
  102. over all the files from the Turbo Access folder to another folder 
  103. that contains your Database Toolbox applications.  While this is
  104. the simplest configuration of the Turbo Access files, it also
  105. results in duplication of the Turbo Access files from project to
  106. project.  The alternative method described below allows you 
  107. to have one copy of the Turbo Access folder for multiple Database 
  108. Toolbox applications; please note that this method will work only 
  109. with the HFS system.
  110.  
  111. Instead of making copies of the Turbo Access files for each project
  112. you are working on, keep one copy of the files and develop each of
  113. your projects in folders nested in your Turbo Access folder. Using
  114. the $O and $I compiler directives, as described below, you will be
  115. able to compile custom versions of SetConst.pas, TAccessUnit and
  116. TAHigh.Unit for each of your projects.
  117.  
  118. The general procedure to follow in developing a Turbo Access program
  119. would be:
  120.   1. Create a folder in your Turbo Access folder that will contain
  121.      your project.
  122.   2. Temporarily modify the $I directive in SetConst.pas to get the 
  123.      .type file from the appropriate folder.
  124.      
  125.       program SetConst;
  126.        {$R SetConst.rsrc} 
  127.        {$U-}
  128.        {$U ConstUser}
  129.        uses MemTypes, QuickDraw, OSIntf, ToolIntf, 
  130.             PackIntF, PasInOut, ConstUser;
  131.        
  132.        {$I :the_name_of_your_project_folder:   .types }
  133.                                         {    ^^ Include file with your
  134.                                         type declarations for MaxDataType
  135.                                         and MaxKeyType }
  136.  
  137.   3. Run SetConst.pas and put the generated constants definition file
  138.      in the appropriate folder(your project folder).
  139.   4. Add a $O directive(indicating where to put the compiled unit) to
  140.      TAccess.Unit and fill in the $I compiler directive indicating the
  141.      location and name of the constant definition file.
  142.   
  143.       unit TAccess(7);
  144.       {$0 :the_name_of_your_project_folder:TAccess}
  145.    
  146.       interface
  147.       {$U-}
  148.       uses MemTypes, QuickDraw, OSIntF, ToolIntf,PackIntf, PasInOut;
  149.  
  150.       {$I :the_name_of_your_project_folder:        .const} 
  151.                                         {   ^^^^^^^ Insert the name of 
  152.                                         your file of Turbo Access 
  153.                                         constants. }
  154.  
  155.   5. Compile TAccess.Unit to disk.
  156.   6. Add a $O directive(indicating where to put the compiled unit) to
  157.      TAHigh.Unit and modify the $U directive to indicate where the
  158.      TAccess unit is.
  159.      
  160.       unit TAHigh(8);
  161.       {$O :the_name_of_your_project_folder:TAHigh}
  162.  
  163.       interface
  164.       {$U-}
  165.       {$U :the_name_of_your_project_folder:TAccess}
  166.       uses MemTypes, QuickDraw, OSIntF, ToolIntf, PackIntf, PasInOut, 
  167.            TAccess;
  168.  
  169.   7. Compile TAHigh.Unit to disk.  
  170.  
  171.  
  172. 4. INCOMPATIBLE UNIT VERSIONS
  173. -----------------------------
  174. When you are compiling a program that uses one of the Database
  175. Toolbox units, you may receive compiler error #89: "Incompatible
  176. Unit Versions".  This will occur when the Database Toolbox unit
  177. is compiled with Turbo Pascal version 1.1 and you are compiling
  178. with version 1.0.  If this occurs, you must open up the source file 
  179. to the specific unit that is incompatible and recompile it to disk.
  180.  
  181.  
  182.  
  183. 5.  DATABASE TOOLBOX WITH MULTIFINDER
  184. -------------------------------------
  185. To run programs created with Database Toolbox under MultiFinder, it 
  186. is recommended that you compile the program to disk, exit Turbo
  187. Pascal by clicking on the Finder from the apple menu, and run the 
  188. program by double-clicking on the icon from the desktop.  You
  189. should not attempt to compile and then run the program from memory
  190. within the Turbo Pascal integrated environment.
  191.    
  192.    
  193. USING THE LIST MANAGER WITH THE DATABASE TOOLBOX
  194. ------------------------------------------------
  195. The Btree.Pas program uses the List Manager Package, which 
  196. is available only from versions of the System numbered 3.2
  197. or higher.  Please contact your Apple dealer to obtain an
  198. updated System disk if you are using a System version less
  199. than 3.2.
  200.  
  201. FILES ON THE DISK
  202. -----------------
  203.  
  204. Turbo Access Folder
  205.   SetConst.pas   - A configuration program for the Turbo Access unit
  206.   SetConst.rsrc  - Rmaker compiled resource used by Setconst.Pas
  207.   TAccess.unit   - Low-level database routines used by all programs
  208.   TAccess.r        - Rmaker source file for resource used 
  209.                          by TAccess.Unit
  210.   TAccess.rsrc   - Rmaker compiled resource for TAccess.Unit
  211.   TAHigh.unit    - High-level database routines
  212.  
  213. Access Samples Folder
  214.   HITAdemo.pas     - Demonstration program for using the high-level
  215.                                database routines in the TAhigh.Unit.
  216.   TADemo.pas       - Demonstration program for using the low-level
  217.                                database routines in the TAccess.Unit
  218.   TADemo.const     - Constants used by HITAdemo.Pas and
  219.                                 TAdemo.Pas
  220.   TADemo.types     - Type definitions used by HITAdemo.Pas
  221.                                and TAdemo.Pas
  222. Btree Sample Folder
  223.   Btree.pas       - Sample database program using TAccess unit
  224.   Btree.const     - Constants used by Btree.Pas
  225.   Btree.types     - Type definitions used by Btree.Pas
  226.   BtreeTA.unit    - BTree's Turbo Access interface unit
  227.   Btree.r         - Rmaker source file for resource used by Btree.Pas
  228.   Btree.rsrc      - Rmaker compiled resource used by Btree
  229.  
  230. Const Source Folder
  231.   ConstUser.unit  - Calculation unit used by Setconst.Pas
  232.   SetConst.r      - Rmaker source file for resource used by
  233.                     Setconst.Pas
  234. Turbo Sort Folder
  235.   Sort.unit        - Routines to implement a Quicksort for 
  236.                            up to 32K items
  237.   Sort             - Compiled version of Sort.unit
  238.   LSort.unit       - Routines to implement a Quicksort for over
  239.                            2 billion items
  240.   LSort            - Compiled version of LSort.unit.
  241.  
  242. Sort Samples Folder
  243.   SortEx1.pas      - Sort demonstration program using Sort.Unit
  244.   SortEx2.pas      - Multiple key sort demonstration program using
  245.                              Sort.Unit
  246.   Stock.data       - Data file used by sort example programs.
  247.   Customer.data    - Data file used by sort example programs.
  248.