Hello
  Please use main function and everthinh will be resolved. okey


>From: Marcel van Kooy <[EMAIL PROTECTED]>
>Reply-To: A mailing list about Java Server Pages specification and
>     reference <[EMAIL PROTECTED]>
>To: [EMAIL PROTECTED]
>Subject: Connection to a database - failure
>Date: Mon, 31 Jul 2000 12:02:06 +0200
>
>Hi all,
>
>Can somebody please help me with this problem.
>When I compile this source-code, for making a connection to a database,
>I'll receive the error "type expected" in the first TRY-statement.
>How can I solve this and what does it mean?
>Thanks,
>Marcel van Kooy
>
>import java.sql.*;
>
>public class TestBean {
>
>     try {
>         Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
>     }
>
>     catch( Exception e ) {
>         System.out.println("Failed to load JdbcOdbcDriver.");
>         return;
>     }
>
>     try {
>         Connection con =
>DriverManager.getConnection("jdbc:odbc:Studio_Bezoekers", "", "");
>         Statement select = con.createStatement();
>         ResultSet result = select.executeQuery
>                             ("...A query...");
>
>===========================================================================
>To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
>JSP-INTEREST".
>Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to