Peter Galantha <[EMAIL PROTECTED]> writes:

> Hi there!
> 
> I'm using the following code to build a connection between a java servlet and
> a postgresql database.
> The main code worked when i used a jdbc driver, but i want to use the pool feature
> of turbine. The Turbineresources.properties file is correct, (i think) becouse
> dbConn.getURL() gives back the url i want.
> The error i find it is in line
> Statement st = db.createStatement(); 
> as i commented in the code: NullpointerException.
> can you help me to find the errors please?
> 
> thanks
> 
> Peter Galantha
> 
> --------------- part of test.java ----------------
> DBConnection dbConn = null;
> try
> {
>       dbConn = TurbineDB.getConnection("stat");
>       Connection db = dbConn.getConnection();
>       response.setContentType("text/html");
>       PrintWriter out = response.getWriter();
>       out.println("<html><body> ");
>       Statement st = db.createStatement();  // ERROR MESSAGE HIER: 
>NullPointerException

Hi Peter.  The connection pool also needs a JDBC driver appropriate
for your database.  You configure this via the
TurbineResource.properties file.
-- 

Daniel Rall <[EMAIL PROTECTED]>


------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to