Underground II
Database Access: In Java
Database Access: In Java
In page, import needed libraries
<%@ page import="java.sql.*, javax.sql.*, javax.naming.*" %>
Obtain a reference to the DataSource using JNDI
<% InitialContext aContext = new InitialContext();
DataSource myDataSource = (DataSource) aContext.lookup(“java:comp/env/jdbc/cfexamples”);%>
Previous slide
Next slide
Back to first slide
View graphic version
|
Home
|
Photos
|
Maps
|
CF Conf Central
|
Please send comments/questions to
[email protected]