cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Berin Loritsch <blorit...@apache.org>
Subject Re: C2 sql examples.
Date Tue, 20 Feb 2001 03:08:38 GMT
Ulf Holm Nielsen wrote:
> 
> hi,
> 
> yep... the following code works just fine...
> 
>   {
>      Class.forName("org.gjt.mm.mysql.Driver");
>      dbcon =
> DriverManager.getConnection("jdbc:mysql://localhost/cocoontest",
> "dullerdaller", "blablabla");
>      dbcon.setAutoCommit(true);
>    }
>    catch ( Exception e)
>    {
>      e.printStackTrace();
>    }
> 
> what could be wrong?

How are you connecting?  Are you using the manual SQL connection
(i.e. specifying dburl, class, username, and password every time),
or are you using the Pooling functionality?

If you are using the Connection Pool functionality, have you specified
the class of your Database Driver in the "load-class" initial parameter
for the servlet?

> 
> Ulf Holm Nielsen
> 
> Donald Ball wrote:
> 
> > On Mon, 19 Feb 2001, Ulf Holm Nielsen wrote:
> >
> >> i've succesfully installed cocoon2 but have some troubles getting the
> >> sql examples to work.
> >>
> >> i've created the mentioned tables in mysql downloaded a jdbc driver and
> >> placed it in the tomcat dir. and changed the driver and table/userinfo
> >> in the xconf..
> >>
> >> however when i run the app simple-sql it gives me (error 1 see below)..
> >>
> >> but when running hte sample forms i get something different. (see error
> >> 2 below)
> >>
> >> anyone got a clue?
> >
> >
> > can you tell me this - does Connection.setAutoCommit(true) fail for you if
> > you call it from a standalone jdbc program?
> >
> > - donald
> >
> >
> > ---------------------------------------------------------------------
> > Please check that your question has not already been answered in the
> > FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> >
> > To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> > For additional commands, e-mail: <cocoon-users-help@xml.apache.org>
> >
> 
> ---------------------------------------------------------------------
> Please check that your question has not already been answered in the
> FAQ before posting. <http://xml.apache.org/cocoon/faqs.html>
> 
> To unsubscribe, e-mail: <cocoon-users-unsubscribe@xml.apache.org>
> For additional commands, e-mail: <cocoon-users-help@xml.apache.org>

Mime
View raw message