![]() |
Copyright © TIBCO Software Inc. All Rights Reserved |
A subview, which is a limited view of a source data table at either a local or remote location, aids in data privacy, increases data security, and often simplifies data access. Changes made in a subview are reflected in the source table but a user of a subview does not have full access to all the data in the source table. You must have DEF_VIEW access to the source table to define a subview of it.The following table describes the behavior of fields, event rules, and parameters as defined in the source and subview tables:
Elements Defined in Source Table Fields in the source table not defined in the subview. Fields in the source table defined in the subview. Can be part of either the selection criteria or defined as parameters to the subview. Complete the following tasks to define a subview table. These tasks are described in the following sections.
Go to page ... Refer to Defining a Subview on a Minimal Definition for the tasks required to define a subview on a minimal table definition.Task A Specify the table typeAfter entering the initial Table Definer screen, described in Accessing the Table Definer, you must change the Type field to SUB. When you press Enter, a screen similar to the following appears.
Task B Specify the source tableIn the Source field, type the name of the table that is your source of data. The source table must already exist and it must be one of the following types of tables: TDS,VSM, DB2, DAT, IDM, IMS, SLK, ADA, or IMP.When the source name is provided and you press Enter, the screen is populated with parameter and field names from the source table. The parameter types and primary key are also identified. The values supplied can be edited.Task C Specify the lock modeIn the Lock Mode field, type in B if you do not want locks to be taken on the data. If locks are not taken, users can only browse the data. Type in D if you want the transaction to determine whether updates are allowed.Task D Select the dataIn the Select field, enter selection criteria for data for the subview. Occurrences being inserted into or deleted from the table must meet the selection criteria. For occurrences being replaced, both the old and new must meet the selection criteria. If no selection criteria is specified, all occurrences in the table are available for use.The selection criteria must be a field name or a data parameter name from the source table, followed by a relational operator, followed by one of: a value; a field name from the source table; a new subview parameter; or an expression. The expression can include only a source field and a constant, or a defined parameter and a constant.
If a data parameter of the source table is not specified in the parameter area of the subview, it must be selected in the selection field as: source_parameter_name=value.If a data parameter of the subview is a field of the source table, it must be selected as: source_field_name=subview_parameter_name.To select occurrences that meet the following criteria: position of ANALYST or employees earning more than $400.00, and the source field MGR# set to the parameter MANAGER# in the subview, enter the following:Task E Define the parametersDefine the parameters in the same way as described in Task B: Define Parameters, except for the following differences:
• A data parameter of a source table, if it is not defined in the subview, must be selected in the selection area of the subview screen as previously described.
• A data parameter in a subview can be a field of the source table, but it must be selected in the selection area of the subview screen as previously described.
• The names of the parameters can differ between the subview and the source table. If the names differ, the value in the Src field must be set to S and the name of the parameter in the source table must be provided in the Source Name field.Task F Define the fieldsDefine the key and non-key fields in the same way as described in Task D: Define Primary Keys and Task E: Define Non-key Fields, noting the following:
• Some or all of the non-key fields named in the subview can be the same as those in the source table.
• Some of the fields in the subview could be renamed from the source table but still derive their values from the source table.
• Only the name and primary key setting of the source fields are imported from the source table. The other attributes, such as syntax and length, are left unspecified. Unless you override these other attributes in the subview table, they are inherited from the source table.
• Ordering and default values are not permitted for fields with syntax RD (raw data) or UN (Unicode).
• Some of the fields could be new fields unique to the subview and derive their value through a functional rule.Use the Src field and Source Name field to set the value or name to be used, as shown in the following table:
Value Src Field If a functional rule is named, the table must be viewed and edited using the shareable tools STEBROWSE and STE. For information about these tools, refer to TIBCO Object Service Broker Shareable Tools. For information about coding the functional rule, refer to Chapter 7, Coding Considerations for Event, Location, and Derived Value Rules.
![]() |
Copyright © TIBCO Software Inc. All Rights Reserved |