Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Name "jdbc/cmssd" not found in context "java:comp/env".

Posted on 2006-06-15
9
570 Views
Last Modified: 2010-08-05
heelo,

 

when I connect to sql server db I get error :

 

[6/15/06 14:50:00:105 CST] 70f8e552 SystemErr R javax.naming.NameNotFoundException: Name "jdbc/cmssd" not found in context "java:comp/env".

[6/15/06 14:50:00:105 CST] 70f8e552 SystemErr R at com.ibm.ws.naming.ipbase.NameSpace.lookupInternal(NameSpace.java:1021)

[6/15/06 14:50:00:105 CST] 70f8e552 SystemErr R at com.ibm.ws.naming.ipbase.NameSpace.lookup(NameSpace.java:932)

[6/15/06 14:50:00:105 CST] 70f8e552 SystemErr R at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1261)

[6/15/06 14:50:00:105 CST] 70f8e552 SystemErr R at com.ibm.ws.naming.urlbase.UrlContextImpl.lookup(UrlContextImpl.java:1307)

[6/15/06 14:50:00:105 CST] 70f8e552 SystemErr R at com.dc.enterprise.Query.buildConnection(Query.java:68)

0
Comment
Question by:royalcyber
9 Comments
 
LVL 92

Expert Comment

by:objects
ID: 16917306
is that name defined in your context?
0
 

Author Comment

by:royalcyber
ID: 16917320
can u pls explin

what do u mean by "... is that name defined in ur context..."
0
 
LVL 92

Expert Comment

by:objects
ID: 16917327
your application context needs to define what that name is referring to.
What is the application that is trying to lookup that name?
0
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

 

Author Comment

by:royalcyber
ID: 16917342
it is a  shopping cart application

i just have the jar file not the source code

I was told :

 You need to setup the jndi name in the workspace for jdbc/cmssd pointing to the cms database similar to jdbc/cms. This is in the ear you are attempting to load.
0
 
LVL 92

Expert Comment

by:objects
ID: 16917361
so what have you done to setup the name?
How are you running the jar?
0
 

Author Comment

by:royalcyber
ID: 16917370
I am suing Websphere application developer


i have set up the name in the datasource section of the server

but it is still giving the error
0
 
LVL 92

Expert Comment

by:objects
ID: 16917377
can you post the name definition
0
 
LVL 30

Expert Comment

by:Mayank S
ID: 16920849
Pls post your XML configuration file.
0
 
LVL 4

Accepted Solution

by:
orhanbaba earned 500 total points
ID: 16926616
this is a sample config. put this lines before </host> tag. on TOMCAT_HOME/conf/server.xml


<Context path="/contextname" docBase="document_root_directory"
debug="5" reloadable="true" crossContext="true">
<Resource name="jdbc/db_dbname" auth="Container" type="javax.sql.DataSource"
maxActive="9" maxIdle="2" maxWait="10000" username="db_kullanici_adim"
password="password" driverClassName="com.mysql.jdbc.Driver"
url="jdbc:mysql://127.0.0.1:3306/db_adi?autoReconnect=true"
removeAbandoned="true"
removeAbandonedTimeout="60"
factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory"/>
</Context>
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
custom annotations 9 42
eclipse buid path vs tomcat lib path 10 34
Java program running SQL query 5 37
collection output issue 9 36
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question