Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java Databases > Re: trouble con...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 9 of 11 Topic 3700 of 3800
Post > Topic >>

Re: trouble connecting to mysql

by naveen <naveen.cse217@[EMAIL PROTECTED] > Apr 9, 2008 at 06:02 AM

> You have loaded the driver OK, you have established a TCP connection
> to the server OK, but the JDBC driver and the MySQL server will not
> talk to each other. It look like the MySQL server closes the connection.
>
> Check that the JDBC driver you are using are newer than the MySQL
> server version you are using.
>

i am using |mysql-connector-java-5.1.6| connector
and |mysql-5.0.51a-win32| mysql database
i think these are latest versions and probably should comply with each
other.

> Check in the MySQL side for errors.
>
how do i do that ? please elucidate
other than this, i tried connecting to mysql
using jndi as described in the apache tomcat do***entation

but it's example jsp uses jstl
the test.jsp is of form:
________________________________
<%@[EMAIL PROTECTED]
 taglib uri="http://java.sun.com/jsp/jstl/sql"
prefix="sql" %>
<%@[EMAIL PROTECTED]
 taglib uri="http://java.sun.com/jsp/jstl/core"
prefix="c" %>

<sql:query var="rs" dataSource="jdbc/TestDB">
select id, foo, bar from testdata
</sql:query>

<html>
  <head>
    <title>DB Test</title>
  </head>
  <body>

  <h2>Results</h2>

<c:forEach var="row" items="${rs.rows}">
    Foo ${row.foo}<br/>
    Bar ${row.bar}<br/>
</c:forEach>

  </body>
</html>
____________________________________________

the described jndi example works but i dont know jstl
and i need to use simple jsp coding

now if anyone would do me a favor by converting the test.jsp as shown
to a simple jsp (i.e. without using the jstl) then my problem would
stand
solved for now

somebody please help
 




 11 Posts in Topic:
trouble connecting to mysql
naveen <naveen.cse217@  2008-04-06 10:03:41 
Re: trouble connecting to mysql
=?ISO-8859-1?Q?Arne_Vajh=  2008-04-06 15:07:58 
Re: trouble connecting to mysql
Lew <lew@[EMAIL PROTEC  2008-04-06 15:54:55 
Re: trouble connecting to mysql
naveen <naveen.cse217@  2008-04-07 02:28:27 
Re: trouble connecting to mysql
=?ISO-8859-1?Q?Arne_Vajh=  2008-04-07 21:40:57 
Re: trouble connecting to mysql
"joeNOSPAM@[EMAIL PR  2008-04-07 09:23:31 
Re: trouble connecting to mysql
naveen <naveen.cse217@  2008-04-08 19:05:48 
Re: trouble connecting to mysql
=?ISO-8859-1?Q?Arne_Vajh=  2008-04-08 22:24:21 
Re: trouble connecting to mysql
naveen <naveen.cse217@  2008-04-09 06:02:49 
Re: trouble connecting to mysql
Lew <lew@[EMAIL PROTEC  2008-04-09 19:52:50 
Re: trouble connecting to mysql
naveen <naveen.cse217@  2008-04-10 11:56:14 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Jul 26 4:41:46 CDT 2008.