I've only just subscribed to this group, so forgive me if this has been
answered before (is there a archive anywhere?).

        I'm having problems with import classes into my jsp page, for
example:


<%@ page import="java.sql.Connection" />

<HTML>
<HEAD>
<TITLE>Example Page</TITLE>
</HEAD>
<BODY>

<% Connection dbConn =
java.sql.DriverManager.getConnection("jdbc:odbc:TestDSN"); %>

</BODY>
</HTML>


        This will fail to work (probably also because I haven't trapped the
SQLException, but ignore that for this simple example). The point is, the
code for the built servlet does not contain the import declaration, so it
doesnt know what Connection is. If I replace that with java.sql.Connection,
it works. I fail to see the point of the import declaration if it doesn't
actually do anything. It also doesn't seem to work for beans since in all
the examples I have, the beans are imported, then still referenced by their
full class names.

        Am I missing the point here?

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JSP-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to