II. Import Using Existing Mask |
![]() ![]() ![]() |
This is a variation of the above. In I (Add IDB Record), you would use your external database to create a brand new record, with each record comprising two lines, the first being the variable names and the second the data. With this method, you use an existing mask to supply the variable names (giving you more control over their order, spelling, composition, etc., because is it very easy to create and manipulate a mask) and the external database to create the data values only. To complete an Instant Database record, you would recall a mask (from the drop down list in the upper right of an Instant Database screen and then 'import' data from an external comma separated value (.csv or .txt) file. Let's discuss the steps. Most of these steps are one-time setups and will not be repeated. First, create an input form 'mask' that contains the variables for the typical document you want to create. See Create Mask in the main Pathagoras Manual for the instructions on the care and feeding of masks. (If you already have an established mask that you want to use, you are practically ready to roll.) Second, create a comma separated value file from you external database. Here are the rules:
Typically the section of the mask into which you will be importing data will be the 'whole' mask, but it need not be. Maybe it will pair up with the first 10 variables of the mask, in which case the you will create a csv file which contains 10 fields. Maybe you want to allow the user to complete the first 10 fields of the mask, and you want to be able to import data from field 11 to the end. Pathagoras can do either. Just keep in mind that the data must pair up with the desired section of the mask and the only way to accomplish that is to keep the data in the same order as the variables in the mask you wish to pair up with.
Third, in Pathagoras, create a pointer to the export file. This is done on via the Instant Database tab of the All Settings and Options toolbox (1). Toward the bottom of that window, click the External Database Content tab (2). (1)Select the Instant Database tab in the All Settings screen. That is it for the initial setup. Now, let's pretend we assembled a document. It contains variables that are collected in a Mask. Display the Instant Database screen and select the mask from the Mask list (upper left corner of the IDB form. Complete the data that you know is not going to be imported (or do this second). When you are ready to import data from the external file, click Power Tools and then click the 'Import' button in the Power Tools section. From the resulting screen, select the nature of the file from which you wish to import data. In this case, select the last entry, "From prepared .csv file.' this screen will appear, with the data from the first field of the primary import file already displayed. Notes:
|