wood burning stoves 2.0*
The moose likes JDBC and the fly likes Connection through bean error Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Connection through bean error" Watch "Connection through bean error" New topic
Author

Connection through bean error

Michael Crutcher
Ranch Hand

Joined: Feb 18, 2002
Posts: 48
Sorry for cross posting but no one seems to be able to help, and I think this might be more appropriate here (as opposed to the jsp board)
I have a java bean that is accessing a teradata database. The get methods open up a connection, perform a select statement, format the result set, and return a string representing a list box. The problem is that the connection never happens. The bean's get method never returns and hangs at this line:
Connection con = DriverManager.getConnection(url, username, password);
Where url is jdbcdbcataSourceName, username and password should be obvious. The data source is a system dsn. The wierd part is that a tester program calling the exact same get method works just fine, returning a correctly formated list box string. Originally the data source was a user dsn. Thinking this might be the problem I changed it to a system dsn. Could this have anything to do with it? Could it be something within Teradata (I doubt this very seriously since it's just an odbc connection).
Here's the bean getMethod:

Here's the bean call from within the jsp:

Here's the tester call:

Again the tester works fine, returning the expected output. The bean call never returns or throws an exception. It dies on the previously mentioned line.
Any help would be greatly appreciated. I'm dead in the water right now and extremely frustrated.
Please help, your karma will thank you.
Michael Crutcher
 
 
subject: Connection through bean error
 
Similar Threads
JSP Password checking problem
Problem with the ajax app
Invalid user error message
DSN problem
calendar