I could be wrong but isnt <parameter><name>username></name><value>sa</value></parameter>
specific to dbcp .BasicDataSourceFactory ? I am using SQLServerDataSource and according the docs
they specify a param called User whose value should be a user name.

Jacob Kjome wrote:


<parameter><name>User</name><value>sa</value></parameter>

should be....

<parameter><name>username</name><value>sa</value></parameter>

Also, I'm not sure if the names are case sensitive. I suggest using All lower case just to be sure.

Jake

At 05:23 AM 12/3/2002 -0800, you wrote:

Hi
i spent 7 hours trying to figure out the problem, but no luck, anyone with leads pls help!!!!!
i have following data source configuration in server.xml
<Resource name="jdbc/NPGnomonDB" auth="Container" type="javax.sql.DataSource" />
<ResourceParams name="jdbc/NPGnomonDB" >
<parameter><name>factory</name><value>com.ddtek.jdbcx.sqlserver.SQLServerDataSource</value></parameter>
<parameter><name>DatabaseName</name><value>some_Db</value></parameter>
<parameter><name>Password></name><value>sa</value></parameter>
<parameter><name>ServerName></name><value>1.1.1.3</value></parameter>
<parameter><name>User</name><value>sa</value></parameter>
</ResourceParams>
and my web.xml has
<resource-ref>
<description>
Data Source
</description>
<res-ref-name>
jdbc/NPGnomonDB
</res-ref-name>
<res-type>
javax.sql.DataSource
</res-type>
<res-auth>
Container
</res-auth>
</resource-ref>

The class com.ddtek.jdbcx.sqlserver.SQLServerDataSource does implements javax.sql.DataSource

in my source code i have following lines
Context iCtx = InitialContext();
Context ctx = (Context) iCtx.lookup("java:comp/env");
DataSource ds = (DataSource) ctx.lookup("jdbc/NPGnomonDB");

and i get the following error

javax.servlet.ServletException: javax.naming.NamingException: Could not create resource factory instance, com.ddtek.jdbcx.sqlserver.SQLServerDataSource
at org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:146)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:312)
at org.apache.naming.NamingContext.lookup(NamingContext.java:834)
at org.apache.naming.NamingContext.lookup(NamingContext.java:181)
at org.apache.naming.NamingContext.lookup(NamingContext.java:822)
at org.apache.naming.NamingContext.lookup(NamingContext.java:194)


Any leads ??





--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

--
Your favorite stores, helpful shopping tools and great gift ideas. Experience the convenience of buying online with Shop@Netscape! http://shopnow.netscape.com/



--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>



Reply via email to