|
|
|||||
Introducing PTWin32 |
PTWin comes with over 30 modifiable, ready-to-run reports that print out everything from permits to the monthly building tally. If you wish to create new reports you can do so in the Ad Hoc reporter that comes with PTWin, or you can use Paradox for Windows for Workgroups, or the SQL report writer of your choice. If you want to make new reports that draw fields from more than one database table you need to have a basic understanding of the way these tables work together. There are over 50 database tables in PTWin that can contain records related to other records in different tables. A relationship between two different tables is achieved by having a field in both tables that contains the same data. When you create a new report you need to establish connections between the common fields. These connections are referred to as the Data Model. Lets suppose you want to create a report of Contractors that includes all Employee contact information. The Employee contacts are stored in a different table from the one that contains the general Contractor information so that you can have as many contact records as you need. When you create a report you need to specify that it contains fields from both CONTRACT.DB (Contractors), and CONTEMPS.DB (Employee contacts) database files. You will find that each of the database tables contains a field called Contractor Key. Use this field to link the two tables in the Data Model for your report. A word of advice; If you can, check the reports that come with PTWin and either use them as guides or templates to create complex Data Models. Why recreate the wheel? You will find some unusual relationships as you create PTWin Data Models. A notable example involves fields appearing on the Permit Info or Additional Info tabs in PTWin. You decide what fields are displayed on these tabs. We give you this control through the use of a Data Dictionary. A Data Dictionary uses utility fields in a master table to supply slots that you get to fill in. Each slot/field has been named before you assign your display name. In normal PTWin use you never need to know the real name of fields that appear on Permit Info or Additional Info tabs, but when creating output that uses these fields you need to know their real names to place them on your report. In the case of the Permit Info tab the tables that keep track of the names and locations of the utility fields you have assigned to PTWin are stored in 3 database tables called PERMMAP.DB, PERMTYPE.DB, and PERMPAGE.DB. For the Additional Info tab the tables are called MODMAP.DB, MODTYPE.DB, and MODPAGE.DB. To place a field in a report that comes from either PERMINFO.DB (Permit Info tab) or MODINFO.DB (Additional Info tab) look in the Data Dictionary tables to find the real name of a field you have assigned to PTWin. The *TYPE tables assign a number to the Permit Type or Module. Use the number to find your custom fields in the *MAP tables. Find the Display Label for the field you want then look at its Field Name to determine the real name of the field in PERMINFO or MODINFO. Refer to the real name of your custom field when placing it on your new report. The *PAGE tables tell you which Permit Info sub-notebook page contains your field. There are so many products available for the creation of output it is not possible for us to describe the mechanics of any particular product but they will all use Data Models and field names from the Data Dictionary.
|
||||