Hi , Usually in the "resource" tag , we define the name parameter as below:
name="jndi/dbName" Make this change and hopefully it should work. Thanks On Mon, Aug 29, 2011 at 10:20 AM, Alaeddine HAOUAS < a.hao...@nouvellemarque.com> wrote: > Hi, > > > > I try to "backup" a java 1.5 web application with servlet/JSP using > tomcat-6.0.20. > > > > I am having the following error when starting my tomcat in Eclipse (sysdeo > plugin v3.2.1) : > > > > FATAL [main] DatasourceConnectionProvider:47 - Could not find datasource: > dbName > > javax.naming.NameNotFoundException > > > > > > I have read the Context Container documentation to make a correct context > file. I added a context file 'proto.xml' in conf\catalina\localhost. The > file content : > > > > <Context reloadable="true" > docBase="C:\eclipse\workspace-intranet\sadeteProto\web" > workDir="C:\eclipse\workspace-intranet\sadeteProto\work" > > > > > <Environment name="server.name" type="java.lang.String" > value="xxxxx" /> > > <Environment name="jdbc.prefix" type="java.lang.String" > value="" /> > > > > > > <Resource name="dbName" auth="Container" > type="javax.sql.DataSource" > > driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver" > > > > url="jdbc:sqlserver://xxx.xx.xx.xxx:1433?database=DB_copie&autoReconnect > =true" > > username="User_DB" > > password="xxx" /> > > > > </Context> > > > > > > In the hibernate config file I have the following property : > > <property name="connection.datasource">dbName</property> > > > > > > Any idea how to make the datasource visible for my application ? > > > > Thanks > > > > > > Alaeddine > > > >