Platform Framework
R24 AMR | Min(s) read

TAFJ Promoted Columns

This section explains how to promote columns for TAFJ for performance improvements.

Promoted columns are relational columns in which the data is generated through a function when it is inserted or updated for these columns to perform better when indexed over an xml index.

This is applicable for single value columns. To index multi-value columns, see Oracle’s XMLINDEX clause. The advanced use case shows how to index a multi-value without XMLINDEX, but it requires a code change that probably will not work with a normal Temenos Transact use case. Below is an example of an XMLINDEX for Oracle:

create index IX_FBNK_CUSTOMER_NAME_1_3 ON FBNK_CUSTOMER(XMLRECORD) INDEXTYPE IS XDB.XMLINDEX PARAMETERS ('PATHS (INCLUDE (/row/c3))');

If you want to index the multi-values in attribute c3 of the xml document, then the following SQL mode command outputs a script to create a promoted column for indexing.  Use it with the SPOOL command.

tafj@localhost:TB201507>SPOOL

tafj@localhost:TB201507>CREATE-PROMOTED-COL IX_RANK ATTRIBUTE=2 DATATYPE=VARCHAR LENGTH=30 COLNAME=RANK TABLENAME=FBNK_CURRENCY

tafj@localhost:TB201507>SPOOL

The resulting script can be found under $TAFJ_HOME/log/DBTools.

The below example codes show how to promote the RANK column (xml attribute 1) in the FBNK_CURRENCY table in different servers or databases.

Drop and Recreate Views

In all databases, you need to drop and recreate view so that the new column goes directly to the rdbms column and not the XML column when you query the view.  You can retrieve a view from a particular database or generate it using DBImport with DBImport logging set to DEBUG in $TAFJ_HOME/conf/TAFJTrace.properties. This section provides you the examples of getting and recreating views on Oracle and DB2 databases, respectively.

USE CASE

Below is an advanced example with column SCRIPT.GROUP (a multi-value column).

EXT-INDEX

Database index has been created manually on an application or field combination. The same is now achieved with DBTools in SQL mode. The following operations are allowed with EXT-INDEX:

  • CREATE-EXTINDEX
  • DELETE-EXTINDEX
  • LIST-EXTINDEX
These operations apply only to XML tables for Oracle, SQL Server and DB2.

Copyright © 2020- Temenos Headquarters SA

Published on :
Monday, May 27, 2024 5:14:18 PM IST