23 frequently asked questions, Chapter 23: frequently asked questions – HP Integrity NonStop J-Series User Manual

Page 458

Advertising
background image

23 Frequently Asked Questions

23.23.1.1

Why do I get "blobTableName property is not set or set to null value or set to invalid
value OR clobTableName property is not set or set to null value or set to invalid
value error(s)" while running a JDBC application on NonStop system?
BLOB and CLOB are not native data types in SQL/MX database. But, database
administrators can create SQL/MX tables that have BLOB or CLOB columns by
using the JDBC drivers for SQL/MX database or special SQL syntax in MXCI.

Before running the JDBC application that uses BLOB or CLOB data through the
JDBC API, the database administrator must create a LOB table. A LOB table actually
contains the BLOB or CLOB data in chunks. The JDBC application specifies a LOB
table name either through a system parameter or through a Java Property object
by using one of the following properties, depending on the LOB column type:

BLOB blobTableName
CLOB clobTableName

23.23.1.2

Why do I get the error "The statement was not prepared " while creating table
containing a LOB column in the SQL/MX database on a NonStop system?
Because BLOB and CLOB are not native data types in the SQL/MX database, you
need to execute the following SQL Query to enable the creation of tables that have
column containing LOB data type:

CONTROL QUERY DEFAULT JDBC_PROCESS 'TRUE'

23.23.1.3

My application uses the auto-increment feature provided by Hibernate. However,
the application fails to perform any insert operation. What can be the reason for
this?
NonStop SQL/MX does not support the auto-increment feature at database level.
Therefore, if you mention "identity" or "sequence" as the generator class in the
Hibernate application, it will not work.

You can either disable the auto-incrementing feature in Hibernate and manually
enter the values or use generator class other than "identity" or "sequence" in the
Hibernate application such as "native" or "increment".

23.23.1.4

My application is using Hibernate for database operations on NonStop system.
However, the operations performed by the application are not being reflected in
the SQL/MX database. Why?
The following reasons can be attributed to the replication of the problem:

You are using a transaction API, but you have not committed the transaction.
Without committing the transactions, the database will not be updated.

If you are not using transaction APIs, you have either not flushed or closed the
session using which the database operations are performed.

Ensure that you commit a transaction while using any transaction API and either
flush the session or close the session.

23.23.1.5

What type of connection pooling should I use while using Hibernate as the ORM
tool on a NonStop system?
Hibernate offers built-in connection pooling, but it is non-scalable and
non-fault-tolerant. Thus, it is not recommended that you do not use Hibernate’s
build-in connection pooling. Instead, use an external connection pool defined behind
a DataSource such as Commons DBCP or C3P0.

23.23.1.6

Why do I get the error "The statement was not prepared" while a JDBC application
execute an SQL statement on SQL/MX database on a NonStop system?

458 Frequently Asked Questions

Advertising
This manual is related to the following products: