How do I embed a stand-alone version of Mckoi SQL Database into my application?
You need to include the Mckoi SQL Database jar archive in your application classpath. For example; java -cp mckoidb.jar [Your application start class] NOTE: You do not need to include the JDBCTM Driver jar-ball (mkjdbc.jar) because the JDBCTM Driver is included in mckoidb.jar The local database is accessed through the JDBCTM Driver URL. The following code demonstrates how this works; java.sql.Connection connection; try { // Register the Mckoi JDBC Driver, Class.forName(“com.mckoi.JDBCDriver”).newInstance(); // The Database URL specifies that the database is to be // found in the local file system. String url = “:jdbc:mckoi:local://C:/mckoi/db.conf”; // Make a connection to a local database, connection = java.sql.DriverManager.getConnection( url, username, password); } catch (Exception e) { System.err.println(“JDBC Driver initialization failure.”); e.printStackTrace(System.err); return; } // … ‘connection’ is now used to talk with the Database Note that the example above assumes the d