beautypg.com

I frequently asked questions, Appendix i: frequently asked questions – HP Integrity NonStop J-Series User Manual

Page 341

background image

I Frequently Asked Questions

I.I.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

I.I.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'

I.I.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".

I.I.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.

I.I.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.

I.I.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?
One of the most common reasons for this error is the use of "Reserved Words". There
are a set of words reserved to be used by NonStop SQL/MX. To prevent syntax errors,
avoid using these words as identifiers in NonStop SQL/MX SQL statements. In case
you intend to use a reserved word as a column or table name, you must enclose the
reserved word in double quotes (") to access that column or object.

341

This manual is related to the following products: