aspose file tools*
The moose likes JDBC and the fly likes Name java:jdbc is not bound in this Context Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Name java:jdbc is not bound in this Context" Watch "Name java:jdbc is not bound in this Context" New topic
Author

Name java:jdbc is not bound in this Context

Hanna Habashy
Ranch Hand

Joined: Aug 20, 2003
Posts: 532

I am struggling with this error for many hours now.
Tomcat 7.0 inside Eclipse 3.6

Server.xml



Web.xml




I tried first on Eclipse Galileo and Tomcat 6.2, then I upgraded to Eclipse 3.6 and Tomcat 7.0. Same error.

Any help is greatly appreciated.



SCJD 1.4<br />SCJP 1.4<br />-----------------------------------<br />"With regard to excellence, it is not enough to know, but we must try to have and use it.<br />" Aristotle
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29275
    
140

Is the error occuring on server startup or when you call the code to lookup the DataSource? If the later, are you using "java:comp/env/jdbc/MSSQLDataSource" as the name?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Hanna Habashy
Ranch Hand

Joined: Aug 20, 2003
Posts: 532
Jeanne Boyarsky wrote:Is the error occuring on server startup or when you call the code to lookup the DataSource? If the later, are you using "java:comp/env/jdbc/MSSQLDataSource" as the name?


I get the error when I access the datasource. This is an old project that has been running for years. I am doing some maintinance on it, but I cannot deploy it locally.
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 29275
    
140

Jeanne Boyarsky wrote: If the later, are you using "java:comp/env/jdbc/MSSQLDataSource" as the name?

How about this part of the question? When we upgraded the JavaRanch version of Tomcat, we were missing the "java:comp/env". Older versions of Tomcat didn't require it.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Name java:jdbc is not bound in this Context
 
Similar Threads
Unable make database connection using JNDI with tomcat
Connection pooling in tomcat
Error confguring multiple contexts/data sources in Tomcat 5
Unable to configure tomcat 6.0 datasource from within eclipse.
Warning: Resource reference is not defined for JNDI name