Hi there,
using the udb-type2-driver on z/OS DB version 7, we have a problem
getting the connection to the database. The small program we use looks
like this:
Class.forName(" com.ibm.db2.jcc .DB2Driver");
Connection connection = DriverManager.g etConnection(
"jdbc:db2:<data base-name>", "<user>", "<password> " );
Unfortunetely, at this line, we get the following error message at
runtime (stacktrace):
com.ibm.db2.jcc .b.SqlException : Failure in loading T2 native library
db2jcct2
at com.ibm.db2.jcc .t2.a.a(a.java: 31)
at
com.ibm.db2.jcc .t2.T2Configura tion.<clinit>(T 2Configuration. java:74)
at com.ibm.db2.jcc .DB2Driver.conn ect(DB2Driver.j ava:178)
at java.sql.Driver Manager.getConn ection(DriverMa nager.java:539)
at ...
The shell-script we are using to call the program has included these
libraries:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc.jar
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_license_ cisuz.jar
CP=$CP:/RIS/db2/zamt/jcc/lib
Additionally, also these files are included, but should not have any
effects:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_javax.ja r
CP=$CP:/RIS/db2/zamt/jcc/classes/sqlj.zip
Does anyone know, why the exception above occurs? Depending on the
information of the database administration, all necessary libraries are
installed and all packages bound. Really?
Many thanks for your answers.
Ralf 3 2754 rj**@gmx.de wrote: Hi there,
using the udb-type2-driver on z/OS DB version 7, we have a problem getting the connection to the database. The small program we use looks like this:
Class.forName(" com.ibm.db2.jcc .DB2Driver"); Connection connection = DriverManager.g etConnection( "jdbc:db2:<data base-name>", "<user>", "<password> " );
Unfortunetely, at this line, we get the following error message at runtime (stacktrace):
com.ibm.db2.jcc .b.SqlException : Failure in loading T2 native library db2jcct2 at com.ibm.db2.jcc .t2.a.a(a.java: 31) at com.ibm.db2.jcc .t2.T2Configura tion.<clinit>(T 2Configuration. java:74) at com.ibm.db2.jcc .DB2Driver.conn ect(DB2Driver.j ava:178) at java.sql.Driver Manager.getConn ection(DriverMa nager.java:539) at ...
The shell-script we are using to call the program has included these libraries:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc.jar CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_license_ cisuz.jar CP=$CP:/RIS/db2/zamt/jcc/lib
Additionally, also these files are included, but should not have any effects:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_javax.ja r CP=$CP:/RIS/db2/zamt/jcc/classes/sqlj.zip
Does anyone know, why the exception above occurs? Depending on the information of the database administration, all necessary libraries are installed and all packages bound. Really?
Many thanks for your answers.
Ralf
Hi Ralf. The problem is not in your classpath, but in the library
path where an OS process finds it's native libraries. If you must
use a type-2 driver you have to also configure your JVM processes
library path to explicitly include the driver's native library
component, as well as the DBMS client libraries and they typical
OS libraries.
Joe Weinstein at BEA
Hi,
thanks for your fast answer - now it works ...
Unfortunately, another problem occured. Using the type 2-driver and
doing database operations without sending an explicit commit
(autocommit was set to false), the connection itself will do a commit.
Even if the program is killed during operation.
Does anyone know a solution for this or is this still a bug from ibm?
Using type 4-driver, there will be done a rollback operation if killing
the program etc.
Thanx, Ralf
Joe Weinstein wrote: rj**@gmx.de wrote:
Hi there,
using the udb-type2-driver on z/OS DB version 7, we have a problem getting the connection to the database. The small program we use looks like this:
Class.forName(" com.ibm.db2.jcc .DB2Driver"); Connection connection = DriverManager.g etConnection( "jdbc:db2:<data base-name>", "<user>", "<password> " );
Unfortunetely, at this line, we get the following error message at runtime (stacktrace):
com.ibm.db2.jcc .b.SqlException : Failure in loading T2 native library db2jcct2 at com.ibm.db2.jcc .t2.a.a(a.java: 31) at com.ibm.db2.jcc .t2.T2Configura tion.<clinit>(T 2Configuration. java:74) at com.ibm.db2.jcc .DB2Driver.conn ect(DB2Driver.j ava:178) at java.sql.Driver Manager.getConn ection(DriverMa nager.java:539) at ...
The shell-script we are using to call the program has included these libraries:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc.jar CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_license_ cisuz.jar CP=$CP:/RIS/db2/zamt/jcc/lib
Additionally, also these files are included, but should not have any effects:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_javax.ja r CP=$CP:/RIS/db2/zamt/jcc/classes/sqlj.zip
Does anyone know, why the exception above occurs? Depending on the information of the database administration, all necessary libraries are installed and all packages bound. Really?
Many thanks for your answers.
Ralf
Hi Ralf. The problem is not in your classpath, but in the library path where an OS process finds it's native libraries. If you must use a type-2 driver you have to also configure your JVM processes library path to explicitly include the driver's native library component, as well as the DBMS client libraries and they typical OS libraries. Joe Weinstein at BEA rj**@gmx.de wrote: Hi,
thanks for your fast answer - now it works ...
Unfortunately, another problem occured. Using the type 2-driver and doing database operations without sending an explicit commit (autocommit was set to false), the connection itself will do a commit. Even if the program is killed during operation.
Does anyone know a solution for this or is this still a bug from ibm? Using type 4-driver, there will be done a rollback operation if killing the program etc.
Thanx, Ralf
Glad to help. The JDBC spec isn't defined as to whether pending transactional
state is committed or rolled back on connection close, but it seems horrible
if a program fault or external kill can force a possibly incomplete transaction
to commit. Fortunately you have a type-4 driver which behaves as I'd expect.
Unless it's prohibitively slower or buggy, I'd highly recommend you stick with
an all-Java solution.
Joe Weinstein at BEA Systems
Joe Weinstein wrote:
rj**@gmx.de wrote:
Hi there,
using the udb-type2-driver on z/OS DB version 7, we have a problem getting the connection to the database. The small program we use looks like this:
Class.forNam e("com.ibm.db2. jcc.DB2Driver") ; Connection connection = DriverManager.g etConnection( "jdbc:db2:<d atabase-name>", "<user>", "<password> " );
Unfortunetel y, at this line, we get the following error message at runtime (stacktrace):
com.ibm.db2. jcc.b.SqlExcept ion: Failure in loading T2 native library db2jcct2 at com.ibm.db2.jcc .t2.a.a(a.java: 31) at com.ibm.db2. jcc.t2.T2Config uration.<clinit >(T2Configurati on.java:74) at com.ibm.db2.jcc .DB2Driver.conn ect(DB2Driver.j ava:178) at java.sql.Driver Manager.getConn ection(DriverMa nager.java:539) at ...
The shell-script we are using to call the program has included these libraries:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc.jar CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_license_ cisuz.jar CP=$CP:/RIS/db2/zamt/jcc/lib
Additionally , also these files are included, but should not have any effects:
CP=$CP:/RIS/db2/zamt/jcc/classes/db2jcc_javax.ja r CP=$CP:/RIS/db2/zamt/jcc/classes/sqlj.zip
Does anyone know, why the exception above occurs? Depending on the informatio n of the database administration, all necessary libraries are installed and all packages bound. Really?
Many thanks for your answers.
Ralf
Hi Ralf. The problem is not in your classpath, but in the library path where an OS process finds it's native libraries. If you must use a type-2 driver you have to also configure your JVM processes library path to explicitly include the driver's native library component, as well as the DBMS client libraries and they typical OS libraries. Joe Weinstein at BEA
This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Raquel |
last post by:
This question if for UDB on LUW. Suppose I take regular database
backups of my database
Monday: database backup <ts1>
Tuesday: Tablespace reorged and imagecopied <ts2>
Friday: database restored and roll-forwarded to a timestamp <ts3> on
Wednesday.
Now my question is: because the entire database is being
roll-forwarded, I suppose the database roll forward operation will
|
by: Bruce Jin |
last post by:
I wonder how many people are using db2 on Windows?
I know db2 is native to AS400 which has about 800,000 installations.
Thanks!
|
by: Vikrant |
last post by:
Friends,
I have read DB2/UDB 8.x 'RESTORE DATABASE Command', with my 'limited'
knowledge & skill. I think it should address my concern, but I want
advice/ opinion / experience and any care I must take to restore
DB2/UDB 8.x database 64 to 32 bit).
(1) Due to hardware limitaion I can not have 64 bit DB2/UDB 8 on AIX
4.3.3 host. Let us call this as host vhost32. I can migrate 7.2EE
FP11 32bit to 8.x 32 bit on vhost32. This is my test...
|
by: Pete H |
last post by:
Hi All;
I'm trying to get some of the samples that are amply illustrated in
multiple docs to work. When I try to create a Warehouse Center view
"...for MQ Series messages" or use the UDF wizard in Development
Center, I get the following error/warning:
-------------------------------------------------------------------------
MQSeries Integration Functions could not be found on the target
database.
To run the DB2 table UDFs built by this...
|
by: erkki |
last post by:
Hi,
I have to move iSeries library to new DB2 database. Is there any easier
way to do this moving operation than exporting all tables in iSeries
into text files and then import them into DB2 Express?
I am looking for same kind of function like db2move between two DB2
databases.
| |
by: db2group88 |
last post by:
we are using db2 udb v8.2 Express edition on windows 2003,we use third
party vendor software to help replicate one server to another.
Production server has three instances, each instances has one database
under it. So we would see three folders on D drive: DB2 folder, TEST
folder and EDU folder, each database has 5 tablespaces and they exist
on F drive. So I told the client to replicate the three instance
folders on D and the data folder...
|
by: claus.hirth |
last post by:
When I execute the following statment using the Command Center it
works:
LOAD CLIENT FROM 'Y:\\TheFixedWidthData.txt' OF ASC METHOD L ( 1 1,2
11,12 17) REPLACE INTO S00.TheTargetTable NONRECOVERABLE WITHOUT
PROMPTING
Yet when I try to execute the same statement in a PreparedStatement it
does not work, but gives me a SQLException:
|
by: Laurence |
last post by:
Hi there,
I've checked the supported environments list from IBM website
(http://www-306.ibm.com/software/data/db2/linux/validate/), there does
not mention about DB2 UDB V8.1 on RHEL 4.
I know that I can install the latest fixpak for DB2 UDB V8.1 and then
to become DB2 UDB V8.2. So, I just wonder to know: can I install DB2
UDB V8.1 on RHEL 4, then to update the latest fixpak to become DB2 UDB
V8.2? Does it support that?
|
by: Dal Mon |
last post by:
I have always been confused abuot the terminology. What is the
difference between DB2 and UDB? Are they one and the same? Is one a
subset of the other?
Thanks in advance.
-Dal Mon
|
by: db2user24 |
last post by:
I'm trying to invoke a DB2 stored procedure. The stored proc is coded
in C and compiled to a shared library, which has been placed in the
<DB2 dir>/functions directory. The platform is Linux (using 64 bit DB2 UDB).
From the debug log it seems that the stored procedure can't be found,
although I don't know why. I can see that the procedure name is defined in the database, however it can not be invoked.
Can anyone shed any light on what could...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth.
The Art of Business Website Design
Your website is...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |