Scott D. Spiegler said: > I am trying to programatically connect to my DB, but I > am not sure what the connection string should be. I am > using this statement: > > conn = > > DriverManager.getConnection("jdbc:mysql://localhost/test?user=scott&password=cuatro"); > > I am getting this exception message: > > database_test.DBConnector > SQLException: No suitable driver > > SQLState: 08001 > > VendorError: 0 > > Any idea as to what the correct, connection string > might be? > > Thanks, Scott > > ===== > We don't see things as they are, we see things as we are. > --Anais Nin Ok, we are still stuck bck on the old mm.mysql series of drivers and its java 1.3.1 but I think you can just subsitute the current stuff 1st you must 'register the driver' then you need a slightly different connection setup.
Class.forName("org.gjt.mm.mysql.Driver").newInstance(); // we register the driver, use the new driver string here this.conn = DriverManager.getConnection(this.DBUrl,this.dbuser,this.dbpasswd); where DBUrl is a string like "jdbc:mysql://localhost:3306/"+this.dbname; and dbuser and dbpasswd are the strings containing the username and password. -- William R. Mussatto, Senior Systems Engineer Ph. 909-920-9154 ext. 27 FAX. 909-608-7061 PS. we'd update the driver, but is a shared server environment and we have lots of jsp contects and they all have to change at once.. -- MySQL General Mailing List For list archives: http://lists.mysql.com/mysql To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]