Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

java connection for crystal xi

Status
Not open for further replies.

Lhuffst

Programmer
Jun 23, 2003
503
US
Does anyone know how to create a java (jnbi) connection for crystal reports xi. I have a report that uses an odbc but need to switch it to java oriented since it will be run via a jsp page.
Thanks
lhuffst
 
Does Crystal Reports XI not ship with an implementation of JDBC? You will need to use JDBC instead of ODBC for this. (There are 'bridges' you can buy which let you use ODBC connections as JDBC ones within Java, but it's always best to use one tailored for the specific resource if available).

Tim
 
Yes it did but when I tried to create the connection, it keeps telling me that it can't find the driver so I thought that maybe I needed to install something on my pc.
 
I found a ojdcb14.jar in my oracle 9i directory but do not know how to point it to the directory when I try to do the connection.
 
I am brand new to java and actually crystal reports xi hence the following question.

To use a JNDC connection, do you have to use it via a jsp (java) page or can I create the report in crystal using the connection (which doesn't work at this point)?

Where should the CRConfig.xml file reside?
 
You will need to make sure that the ojdbc14.jar is on the java classpath for the application needing it for JDBC connections.

For web servers, the simplest way usually involves putting it into the lib folder under the WEB-INF folder of the web application.

And it's called JDBC, not JNDC, and stands for Java Data Base Connectivity. Have a look at the Java ApiDocs for the classes in java.sql. There are also hundreds of resources on the web for using JDBC. Google should help you here.

You've obviously already got some code since you say that when you tried to create a connection it couldn't find the driver. Maybe you code post the snippet of code if you still have problems.

Tim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top