Previous Topic: Using Open Data Paths


Creating Default Retrieval Access Paths

To improve the performance of your application, try dropping all of the virtual fields from the default RTV access path. You can use this standard with every file you implement in CA 2E that contains virtuals.

The idea is to create an access path that can be used for validation and that does not have any virtual fields. To do this use the following steps:

  1. Zoom into the file. At the Edit Database Relations panel, type Z next to any relation for the selected file and press Enter. Alternatively, you can select option 2 from the Edit Model Object List panel.

    The Edit File Details panel displays.

  2. Rename the default retrieval. Rename the default RTV access path for your file to the name Validation View.
  3. Create a new RTV access path if you require one that contains virtuals.
  4. Rename. Name the new RTV access path Retrieval Index.
  5. Use the new RTV. Base any functions for the file over the new RTV access path that requires those virtual fields.
  6. Create the validation view with a compiler override of SHARE (*YES).

For more information on compiler overrides, see the "Generating and Compiling Your Application" chapter in Generating and Implementing Applications.

CA 2E uses the default RTV Index Validation View for all file validations. This view also uses the index to determine which fields in the file can be virtualized. The fields available for virtualization will default to only those fields present in the file itself. Although it is not generally a good performance technique, you can virtualize fields that are themselves virtualized. You can do this by adjusting the referenced access path of the relation to point to an untrimmed access path using the Edit Access Path Relations panel.