Solved

Null pointer exception connecting to DB

Posted on 2011-09-12
2
267 Views
Last Modified: 2012-05-12
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
Comment
Question by:anotherfn
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 12

Accepted Solution

by:
mwochnick earned 250 total points
ID: 36523099
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
 
LVL 5

Assisted Solution

by:DerZauberer
DerZauberer earned 250 total points
ID: 36523106
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

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo‚Ķ
This post contains step-by-step instructions for setting up alerting in Percona Monitoring and Management (PMM) using Grafana.
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
This tutorial will introduce the viewer to VisualVM for the Java platform application. This video explains an example program and covers the Overview, Monitor, and Heap Dump tabs.
Suggested Courses

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question