Tibero  tbCLI 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  tbCLI Guide

Publication Date: 2020-03-13

Software Version: Tibero 6 (FixSet07)

Edition: v2.1.7.4


Table of Contents

About This Document
1. Introduction to tbCLI
1.1. Overview
1.2. Components
1.2.1. tbCLI Handle
1.2.2. tbCLI Function
1.2.3. tbCLI Error Message
1.3. Program Structure
1.3.1. Initialization Settings
1.3.2. SQL Query Execution and Error Handling
1.3.3. Termination Settings
2. Data Types
2.1. Overview
2.2. Tibero Data Types
2.3. tbCLI Data Types
3. tbCLI Functions
3.1. SQL-99 Standard API
3.1.1. SQLAllocConnect (Deprecated)
3.1.2. SQLAllocEnv (Deprecated)
3.1.3. SQLAllocHandle
3.1.4. SQLAllocStmt (Deprecated)
3.1.5. SQLBindCol
3.1.6. SQLBindParameter
3.1.7. SQLCancel
3.1.8. SQLCloseCursor
3.1.9. SQLColAttribute
3.1.10. SQLColAttributes (Deprecated)
3.1.11. SQLColumnPrivileges
3.1.12. SQLColumns
3.1.13. SQLConnect
3.1.14. SQLCopyDesc
3.1.15. SQLDescribeCol
3.1.16. SQLDescribeParam
3.1.17. SQLDisconnect
3.1.18. SQLDriverConnect
3.1.19. SQLEndTran
3.1.20. SQLError (Deprecated)
3.1.21. SQLExecDirect
3.1.22. SQLExecute
3.1.23. SQLExtendedFetch (Deprecated)
3.1.24. SQLExtProcRaiseError
3.1.25. SQLExtProcRaiseErrorWithMsg
3.1.26. SQLFetch
3.1.27. SQLFetchScroll
3.1.28. SQLForeignKeys
3.1.29. SQLFreeConnect (Deprecated)
3.1.30. SQLFreeEnv (Deprecated)
3.1.31. SQLFreeHandle
3.1.32. SQLFreeStmt
3.1.33. SQLGetConnectAttr
3.1.34. SQLGetConnectOption (Deprecated)
3.1.35. SQLGetCursorName
3.1.36. SQLGetData
3.1.37. SQLGetDescField
3.1.38. SQLGetDescRec
3.1.39. SQLGetDiagField
3.1.40. SQLGetDiagRec
3.1.41. SQLGetEnvAttr
3.1.42. SQLGetExtProcAllocMemory
3.1.43. SQLGetExtProcConnect
3.1.44. SQLGetFunctions
3.1.45. SQLGetInfo
3.1.46. SQLGetStmtAttr
3.1.47. SQLGetStmtOption (Deprecated)
3.1.48. SQLGetTypeInfo
3.1.49. SQLMoreResults
3.1.50. SQLNativeSql
3.1.51. SQLNumParams
3.1.52. SQLNumResultCols
3.1.53. SQLParamData
3.1.54. SQLParamOptions (Deprecated)
3.1.55. SQLPrepare
3.1.56. SQLPrimaryKeys
3.1.57. SQLProcedureColumns
3.1.58. SQLProcedures
3.1.59. SQLPutData
3.1.60. SQLRowCount
3.1.61. SQLSetConnectAttr
3.1.62. SQLSetConnectOption (Deprecated)
3.1.63. SQLSetCursorName
3.1.64. SQLSetDescField
3.1.65. SQLSetDescRec
3.1.66. SQLSetEnvAttr
3.1.67. SQLSetParam (Deprecated)
3.1.68. SQLSetPos
3.1.69. SQLSetScrollOptions (Deprecated)
3.1.70. SQLSetStmtAttr
3.1.71. SQLSetStmtOption (Deprecated)
3.1.72. SQLSpecialColumns
3.1.73. SQLStatistics
3.1.74. SQLTablePrivileges
3.1.75. SQLTables
3.1.76. SQLTransact (Deprecated)
3.2. Tibero API
3.2.1. SQLAllocEnv2 (Deprecated)
3.2.2. SQLAllocHandle2
3.2.3. SQLGetWarningMsg
3.2.4. SQLGetWarningMsgLength
3.2.5. SQLLobClose
3.2.6. SQLLobFreeLoc
3.2.7. SQLLobGetData (Deprecated)
3.2.8. SQLLobGetData2
3.2.9. SQLLobGetLength
3.2.10. SQLLobOpen
3.2.11. SQLLobPutData
3.2.12. SQLLobTruncate
4. tbCLI Error Messages
4.1. Return Codes
4.2. SQLSTATE
4.2.1. 01000 ~01007
4.2.2. 01S00 ~ 01S09
4.2.3. 07001 ~ 07009
4.2.4. 07S01
4.2.5. 08001 ~ 08007
4.2.6. 08S01
4.2.7. 21S01 ~ 21S02
4.2.8. 22001 ~ 22026
4.2.9. 23000, 24000, 25000
4.2.10. 25S01 ~ 25S03
4.2.11. 28000, 34000
4.2.12. 3C000 ~ 3F000
4.2.13. 40001 ~ 40003, 42000
4.2.14. 42S01 ~ 42S22, 44000
4.2.15. HY000 ~ HY024
4.2.16. HY090 ~ HY111
4.2.17. HYC00
4.2.18. HYT00 ~ HYT01
4.2.19. IM001 ~ IM015
4.2.20. 00000, 02000
5. tbCLI and ODBC
5.1. ODBC
5.2. tbCLI and ODBC Integration
5.2.1. Installation in Windows
5.2.2. Installation in UNIX
5.3. tbdsn.tbr and ODBC Data Source Administrator
Index

List of Figures

[Figure 1.1] Client/Server Environment
[Figure 1.2] tbCLI program structure
[Figure 5.1] Tibero 6 ODBC Driver installation check
[Figure 5.2] User DSN - Add
[Figure 5.3] User DSN - Tibero 6 ODBC Driver selection
[Figure 5.4] User DSN - Database connection information input (IP, PORT type)
[Figure 5.5] User DSN - Database connection information input (SID type)
[Figure 5.6] User DSN - Registration Complete

List of Examples

[Example 1.1] Initialization Settings for tbCLI Program
[Example 1.2] SQL query execution of tbCLI program - Direct execution
[Example 1.3] SQL query execution of tbCLI program - Prepared execution
[Example 1.4] Termination Settings for tbCLI Program
[Example 2.1] DATE_STRUCT, SQL_DATE_STRUCT
[Example 2.2] TIME_STRUCT, SQL_TIME_STRUCT
[Example 2.3] TIME_STAMP_STRUCT, SQL_TIMESTAMP_STRUCT