Tibero  Application Developer's Guide

Tibero 6


Restricted Rights Legend

All TmaxData Software (Tibero®) and documents are protected by copyright laws and international convention. TmaxData software and documents are made available under the terms of the TmaxData License Agreement and this document may only be distributed or copied in accordance with the terms of this agreement. No part of this document may be transmitted, copied, deployed, or reproduced in any form or by any means, electronic, mechanical, or optical, without the prior written consent of TmaxData Co., Ltd. Nothing in this software document and agreement constitutes a transfer of intellectual property rights regardless of whether or not such rights are registered) or any rights to TmaxData trademarks, logos, or any other brand features.

This document is for information purposes only. The company assumes no direct or indirect responsibilities for the contents of this document, and does not guarantee that the information contained in this document satisfies certain legal or commercial conditions. The information contained in this document is subject to change without prior notice due to product upgrades or updates. The company assumes no liability for any errors in this document.

Trademarks

Tibero® is a registered trademark of TmaxData Co., Ltd. Other products, titles or services may be registered trademarks of their respective companies.

Open Source Software Notice

Some modules or files of this product are subject to the terms of the following licenses. : OpenSSL, RSA Data Security, Inc., Apache Foundation, Jean-loup Gailly and Mark Adler, Paul Hsieh's hash

Detailed Information related to the license can be found in the following directory : ${INSTALL_PATH}/license/oss_licenses

Document Information

Title: Tibero  Application Developer's Guide

Publication Date: 2020-03-13

Software Version: Tibero 6 (FixSet07)

Edition: v2.1.7.4


Table of Contents

About This Document
1. Data Types
1.1. Overview
1.2. String
1.3. Number
1.4. Datetime
1.5. Interval
1.6. Binary
1.7. Embedded
2. tbJDBC
2.1. Overview
2.2. Installing JDK
2.3. JDBC Standard Features
2.3.1. JDBC 1.0 and JDBC 2.0
2.3.2. JDBC 3.0
2.3.3. JDBC 4.0
2.4. Basic Programming
2.4.1. Connection
2.4.2. Execution
2.4.3. Calling
2.4.4. Commitment and Rollback
2.4.5. Disconnection
3. Trigger
3.1. Overview
3.1.1. Trigger Components
3.1.2. Trigger Types
3.2. Creating a Trigger
4. XA
4.1. Distributed Transaction
4.1.1. Two-phase Commit
4.1.2. In-doubt Transaction
4.2. XA API
4.2.1. XA Functions
4.2.2. xa_open Function Fields
4.2.3. XA Application Programming
4.3. JDBC XA
4.3.1. XA Interface
4.3.2. XA Interface Programming
4.4. Integrating with TP-Monitor
4.4.1. Integrating with Tmax
4.4.2. Integrating with Tuxedo
5. mod_tbPSM
5.1. Overview
5.2. Installing Apache HTTP Server
5.3. Configuring mod_tbPSM
5.4. Creating and Executing a Procedure
5.4.1. Creating a Procedure
5.4.2. Executing a Procedure
5.5. Configuring Auto Login
6. Object Type
6.1. Overview
6.2. Key Concept
6.2.1. Object Type
6.2.2. Object Type Value (Object)
6.2.3. Using a Object Type When Creating a Table
6.2.4. Collection Type
6.3. Object Components
6.3.1. Using Objects in SQL
6.3.2. Object Type Methods
6.4. Object Behavior
6.4.1. Storage of Objects
6.4.2. Object Constructor
7. Collection Type
7.1. Overview
7.1.1. Creating a Collection Type
7.1.2. Creating a Collection
7.1.3. Multi-layered Collection Type
7.2. Example
7.2.1. In Queries
7.2.2. In DML
A. tbJDBC Example
A.1. JdbcTest.class
B. Example of Integrating with Tuxedo
B.1. tb_tux.env
B.2. tb_tux.conf.m
B.3. tmax32.fld
B.4. trans_fml32.tbc
B.5. builds.sh
B.6. insert.c
B.7. select.c
B.8. buildc.sh
B.9. create_table.sql
B.10. run.sh
Index

List of Figures

[Figure 4.1] Basic Two-phase Commit Example
[Figure 4.2] In-doubt Transaction Example

List of Examples

[Example 2.1] Basic Programming Using tbJDBC
[Example 2.2] tbJDBC - Connection
[Example 2.3] tbJDBC - Execution
[Example 2.4] tbJDBC - Prepared Statements Declaration and Parameter Binding
[Example 2.5] tbJDBC - Calling
[Example 2.6] tbJDBC - Disconnection
[Example 3.1] Creating a Trigger
[Example 5.1] Example of a tbPSM Procedure Using HTP Package
[Example 5.2] Sample mod.tbr
[Example 5.3] Sample tbdsn.tbr
[Example 6.1] Object Type
[Example 6.2] Object Type Value
[Example 6.3] Creating an Object Table
[Example 6.4] Viewing an Object Table (1)
[Example 6.5] Viewing an Object Table (2)
[Example 6.6] NULL Objects and Objects' NULL Properties
[Example 6.7] Specifying an Object Table as the Primary Key when Creating an Object Table
[Example 6.8] Setting a Constraint on an Object Column
[Example 6.9] Creating an Index in an Object Column
[Example 6.10] Creating a Function-based Index in an Object Table
[Example 6.11] Select when the Column in the Table is an Object Type
[Example 6.12] VALUE(x) Expression
[Example 6.13] An Update Using a VALUE(x) Expression
[Example 6.14] Invoking a Member Method (1)
[Example 6.15] Invoking a Member Method (2)
[Example 6.16] Creating a SELF Parameter
[Example 6.17] Invoking a Member Method
[Example 6.18] Defining a Map Method in an Object Type
[Example 6.19] Order Method
[Example 6.20] Comparing Methods
[Example 6.21] Static Method
[Example 6.22] Default Constructor
[Example 6.23] User-defined Constructor Method
[Example 7.1] Creating a Collection Type
[Example 7.2] Creating a Collection
[Example 7.3] Multi-layered Collection Type
[Example 7.4] Using a Collection Type in a Query
[Example 7.5] Selecting an OuterJoin of Collection Type
[Example 7.6] When the Result of a Subquery is a Collection
[Example 7.7] Multi-layered Collection
[Example 7.8] Collection that is a Collection of Objects