<%@ page language="java" import="java.util.*" pageEncoding="ISO-8859-1"%>
<%@ page import="javax.naming.*" %>
<%@ page import="javax.sql.*" %>
<%@ page import="java.sql.*" %>
<html>
<%
String JNDINAME = "jdbc/brian";
Connection con=null;
Context ctx;
ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup(JNDINAME);
con = ds.getConnection();
%>
<%=con %>
</html>
<%@ page import="javax.naming.*" %>
<%@ page import="javax.sql.*" %>
<%@ page import="java.sql.*" %>
<html>
<%
String JNDINAME = "jdbc/brian";
Connection con=null;
Context ctx;
ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup(JNDINAME);
con = ds.getConnection();
%>
<%=con %>
</html>