Hitachi

Hitachi Advanced Database Application Development Guide


17.2.1 Handling errors

In the first part of the troubleshooting process, you identify the source of the error. After identifying the source, you then take the appropriate action to resolve the error. The following figure explains the process of identifying the source of an error.

Figure 17‒1: Identifying the source of an error

[Figure]

After identifying the source of the error based on this flow chart, use the following table to find out what action to take.

Table 17‒1: Handling errors

No.

State

Handling procedure

1

State A

An error occurred in an application or the driver manager.

Perform the following steps:

  • Check the configuration of the application or program.

  • Make sure that the HADB client was installed correctly.

  • Make sure that the data sources are registered correctly, and that the connection information is specified correctly.

  • Check the value output for SQLSTATE. Review SQLSTATE and message contents based on resources such as ODBC Programmer's Reference in the MSDN Library.

  • If the error is reproducible, acquire an ODBC trace and use it to identify the ODBC function that caused the error.

2

State B

An error occurred in the driver manager.

Same as the handling procedure for No.1.

3

State C

An error or warning occurred in the ODBC driver.

Perform the following steps:

  • Check the value output for SQLSTATE. For details about SQLSTATE, see the ODBC Programmer's Reference in the MSDN Library, and the description of SQLSTATE for each ODBC function in 16. ODBC Functions. This error is output according to the ODBC implementation conventions.

  • If the error is reproducible, acquire HADB ODBC driver trace information and use it to investigate the nature of the error. Your investigation might focus on the sequence in which ODBC functions were executed, or what kind of error occurred in which ODBC function.

4

State D

An error or warning occurred in the ODBC driver.

Perform the following steps:

5

State E

The connection with the HADB server has not been established.

The HADB server might not be accessible. You need to identify the part of the access route where access fails.

First, perform the following steps:

  • Make sure that the access privileges for the output destination folder for message log files and for the message log files themselves are assigned correctly.

  • Make sure that environment variables are set correctly.

  • Make sure that the HADB client was installed correctly.

If the error still occurs despite all these settings being correct, enable the output of ODBC traces, HADB ODBC driver trace information, and SQL trace information. Then, reproduce the error and analyze the information output in each trace.

If there is no error message and nothing is output in the BI tool or ODBC module, the issue might be with the BI tool or ODBC module.

6

State F

An error occurred in the HADB client.

Check the error cause code and investigate the cause of the error. For details about the error cause code, see 19.8 Return values of the CLI functions.

Potential causes include a path being specified incorrectly in an environment variable or the client definition, or not having the required privileges.

7

State G

An error or warning occurred in the HADB server or HADB client.

Check the message output by HADB, and investigate the cause of the error or warning.

8

State H

The connection with the HADB server has been established.

The HADB server is accessible.

Perform troubleshooting by analyzing the SQL statements and the messages output to the message log file.

If you want to acquire detailed information, enable the output of ODBC traces, HADB ODBC driver trace information, and SQL trace information. Then, reproduce the error and analyze the information output in each trace.

If there is no error message and nothing is output in the BI tool or ODBC module, the issue might be with the BI tool or ODBC module.

The following figure shows the flow of processing when using the HADB ODBC driver to access the HADB server from a BI tool or ODBC module.

Figure 17‒2: Flow of processing when using HADB ODBC driver to access HADB server

[Figure]

If you resolve the error and a different error then occurs, begin the troubleshooting process again starting from identification of the source.