I am just fighting with a similar issue, although not (yet) from JSP, but
from a Java application. You cannot directly access ODBC data sources from
Java, but there are a couple of options that all involve JDBC. One of them
is the JDBC-ODBC bridge, which allows you to access ODBC data sources via
JDBC. Unfortunately, this is (according to Sun) experimental, and in fact
JDK 1.2.2 has some major problems. I was unable to get this working with SQL
Server, although I was able to successfully access an MS Access database via
JDBC-ODBC. There are some third-party drivers, for example a native JDBC
driver for SQL Server (from http://www.inetsoftware.de/), which seems to
work fine. I believe there are also third-party JDBC-ODBC bridges that might
be more robust. Sun has a nice list of JDBC drivers at this URL:
http://java.sun.com/products/jdbc/drivers.html

-Mirko


> -----Original Message-----
> From: A mailing list about Java Server Pages specification and reference
> [mailto:[EMAIL PROTECTED]]On Behalf Of Jeff Brown
> Sent: Tuesday, December 14, 1999 11:30 AM
> To: [EMAIL PROTECTED]
> Subject: ODBC and JSP
>
>
> Let me start by saying that I'm new to the whole JSP game.  I'm an
> ActiveServerPage developer that needs to port all of my ASP's to JSP's for
> the next release of a product I'm working on.
>
> What I need to do is open a connection to an ODBC source (in this
> case a SQL
> 7.0 Database) and run simple SQL calls against it.  The code I
> would use in
> an ASP is:
>
>         Set Conn = Server.CreateObject("ADODB.Connection")
>         Conn.Open "dsn=SQLCharDB;uid=sa;pwd="
>
> First of all, I need to figure out how to set up an ODBC connection to my
> SQL DB on a Solaris 7 box.  Then I need to learn the correct syntax for
> opening a connection to said ODBC from inside my JSP's.  Currently the web
> server I'm using is Netscape Enterprise 4.0, but I'll eventually be using
> Apache as well.
>
> Any information would be greatly appreciated.
>
>
> Jeffrey W. Brown
> Test Engineer
> Citr!x Systems, Inc.
> PHONE: (954) 267-2846
> EMAIL: jeff.brown @ citrix.com
>
> ==================================================================
> =========
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> FAQs on JSP can be found at:
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
FAQs on JSP can be found at:
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html

Reply via email to