|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
|
|
#1
|
|||
|
|||
|
Class not found
I am trying to connect to Interbase database running on Tomcat. I have one error
An error occured between lines: 12 and 52 in the jsp file: /database/Connection.jsp Generated servlet error: F:\Tomcat\work\localhost\_\database\Connection$jsp.java:70: Class org.apache.jsp.DataSource not found. DataSource dataSource = new interbase.interclient.DataSource(); ^ 1 error I have done it exactly as it says in the books yet it will not run. Can anyone help me please. Here is my code: <%@ page import="java.sql.*"%> <%@ page import="interbase.interclient.DataSource.*"%> <html> <head> <title></title> <link rel="STYLESHEET" type="text/css" href="include/style.css"> </head> <body bgcolor="#cccccc"> <% DataSource dataSource = new interbase.interclient.DataSource(); try { // Set the standard properties dataSource.setNetworkProtocol("jdbc:interbase:"); /* set the network protocol */ dataSource.setServerName("//localhost"); /* the hostname or IP address of the server */ dataSource.setDatabaseName("c:/Jsptest.gdb"); /* the full path to your database file */ dataSource.setDataSourceName("SomeName"); /* a descriptive name */ dataSource.setDescription("SomeDescription"); /* a descriptive comment */ dataSource.setPortNumber(8080); // Set the non-standard properties dataSource.setSweepOnConnect(false); /* Perform a sweep when connecting */ // The following line actually starts up the database connection: Connection con = dataSource.getConnection(SYSDBA,masterkey); |
|
#2
|
|||
|
|||
|
It cannot find the Interbase class files. You either need to make sure the (jar?) file(s) are/is in the correct place or that the classpath being used by the servlet engine correctly points to their location.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages > Java Help > Class not found |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|