Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Connecting to MySQL
millvall
I downloaded and ran the simple report to write to an Access database.
All OK. I replicated the code for MySQL as shown below. I get exception on java.lang.Class.forName. (The Data Source connector in the BIRT report works fine with same JDBC driver.) Is there a CLASSPATH setting I need to set up?
Thanks
Milt.
importClass( java.sql.DriverManager );
var userName = "root";
var password = "";
var url = "jdbc:mysql://localhost:3306/classicmodels";
// Load the driver class -- ** NEXT LINE causes error **
java.lang.Class.forName("com.mysql.jdbc.Driver").newInstance ();
// Get a connection
// var conn = DriverManager.getConnection (url, userName, null);
// conn.close();
-- eom --
Find more posts tagged with
Comments
There are no comments yet