Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 274
  • Last Modified:

Null pointer exception connecting to DB

We have server side Java code from a third party, and are trying to connect it to our database.  The third party provided a jar file for their proprietary database code, and we have included that within the project's build path.  The project compiles correctly, but at runtime we are getting a null pointerexception when trying to call any functions from within the jar file.  Is there something else that we should do so that the Java code can access the jar file?
0
anotherfn
Asked:
anotherfn
2 Solutions
 
mwochnickCommented:
there could be a lot of different problems - is their a config file that needs to be in the runtime classpath, are there missing configuration parameters that it needs, etc.  Its hard to tell without more info.  Please post the stack trace and any error messages, it would also be useful to know what the db is (vendor and version) and the third party jar (vendor and version)
0
 
DerZaubererCommented:
Is your app a web app running in a servlet container? Make sure to include the .jar file in your WEB-INF/lib folder and deploy with the application then.
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now