This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes JDBC and the fly likes Batch Update Problem Help required. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Batch Update Problem Help required." Watch "Batch Update Problem Help required." New topic
Author

Batch Update Problem Help required.

Devesh H Rao
Ranch Hand

Joined: Feb 09, 2002
Posts: 687

hi all,
I have a java class in which i am calling a batch update statement on a prepared statement but i am getting an exception which says
" java.lang.UnsatisfiedLinkError: SQLBindShortArray "
The update and execute queries run fine so i suppose there is no problem with the connection as such this problem arises only in case of batch update proble.
we are using DB2 as the database
any help or references regarding the problem will do...
Devesh Rao
Kevin Mukhar
Ranch Hand

Joined: Nov 28, 2000
Posts: 83
Consulting the Javadoc for UnsatisfiedLinkError gives this explanation:
public class UnsatisfiedLinkError
extends LinkageError
Thrown if the Java Virtual Machine cannot find an appropriate native-language definition of a method declared native.
In other words, the driver relies on native code libraries (.dll for Win, .so for Solaris) to do its work. It cannot find the native code library that contains the function SQLBindShortArray. This may mean that the library is not on your system, or it might be on your system but not on the PATH (Win) or LD_LIBRARY_PATH (Unix).
Devesh H Rao
Ranch Hand

Joined: Feb 09, 2002
Posts: 687

hi kevin..
Thanx for the response ...
we had debugged to the point that the drivers were not supporting the native call but we first worked with the database and appserver both on windows o/s machines and everything worked fine.
The problem started arising when we moved the database on to a linux o/s machine
we are using the same jdbc drivers and app server
version and the configuration is also the same the only difference being the database is now hosted on a different o/s ..as you suggested we will check if previously we were using the system variables to provide the path to the drivers and rectify it ....
can u suggest any other things we need to check now that the database is on a linux based system..
Devesh.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Batch Update Problem Help required.