When you access external DBMS data from TIBCO Object Service Broker, it translates the request into an external (ODBC or Oracle) API call and external DBMS field data types are translated to the TIBCO Object Service Broker field types defined in the SLK table. To access the SLK tables for external data access, you can use various workbench tools, such as the Table Browser and the Table Editor, or you can use the rules language.
When a TIBCO Object Service Broker request for SLK data is first processed by the Gateway, TIBCO Object Service Broker generates an SQL statement. This statement contains references to table columns as outlined in the SLK definition. As some SQL-specific rules apply, the table definition contains the Vrt field (refer to
Vrt) to provide the issuer of the request with some control over this process.
The names of the columns in the SQL statement appear exactly as specified in the external name field of the SLK definition, possibly enquoted. This means that any expression that makes sense for the target DBMS can be specified. You use the Vrt field as follows:
|
|
|
|
|
The column must not be updated, that is, its name must appear neither in the SET clause of an UPDATE statement nor in the column list of an INSERT statement.
|
|
Q, 1, 2, 3, or 4, as required
|
The nature of the column name is such that it must be enquoted whenever used (for example, “DELETE”, “Number of items”).
|
|
|
The column must not appear in the column list of an INSERT statement (for example, member of Oracle's object such as address.street).
|
|
|
The column must appear only in the WHERE clause (for example, an expression with side effects). The value of the column in any row retrieved is NULL.
|
|
|
The column's default value must by used “as is” in the VALUES clause of an INSERT and the SET clause of an UPDATE statement (for example, if an SLK definition maps an Oracle table and SEQ is an Oracle sequence, SEQ.NEXTVAL specified as default for a column in that definition results in behavior similar to TIBCO Object Service Broker's IDgen).
|
|
|
|
|
|
|
Quoted and Expression as default
|
|
|
Member of class and Expression as default
|
|
|
When using Where only in complex WHERE clauses, TIBCO Object Service Broker can transform the original logical expression into an equivalent DNF (disjunctional-normal form) with a different number of column references. For example, the expression (R1 & (R2 | R3)) is submitted to the target DBMS as (R1 & R2) | (R1 & R3), where R1, R2, and R3 are logical terms <field><relational-operator><value>. Also, if <value> in a term is an expression, the term is excluded from the WHERE clause passed to the target DBMS, so that TIBCO Object Service Broker, as opposed to the target, carries out the evaluation of the rows upon return from the target DBMS.
Use the Table Browser to browse a defined SLK table by typing the table name next to the BR browse table option and pressing Enter. To edit a table, type the table name next to the ED edit table option and press Enter. In both cases a screen similar to the following appears.
Using the Table Browser or the Table Editor, you browse and edit an SLK table in the same way you would browse or edit any other TIBCO Object Service Broker table.
If your table definition contains fields longer than 260 bytes, you must do one of two things: use the Single Occurrence Editor (SOE) from the Table Editor to edit them and use
SELECT LIKE to retrieve occurrences based on the values of these fields.