Knowledgebase: MySQL Questions
Can you give me an example of how to connect to one of the MySQL databases using JSP?
Posted by Russell Rademacher on 22 November 2009 09:58 AM
Below is an example:

yourusername_dbname

Connection connection = null;
Class.forName("org.gjt.mm.mysql.Driver").newInstance();
connection = DriverManager.getConnection(
"jdbc:mysql://localhost/yourusername_dbname?user=&password=");
(122 vote(s))
Helpful
Not helpful

Comments (0)
Post a new comment
 
 
Full Name:
Email:
Comments: