Heads Up :
The post you are writing will appear in a public forum. Please ensure all content is appropriate for public consumption. Review the employee guidelines for the community here.
I've attahced server.xml in C:\Program Files\Apache Group\Tomcat 4.1\conf
Thank you.
Subject: RE: JNDI setup Replied by: Michael Bochynski on 09-12-2004 04:53:20 PM Hi,
Please make the following changes to your JDBC configuration:
1. Change the [i:f9bd38d066]"user"[/i:f9bd38d066] to [i:f9bd38d066]"username"[/i:f9bd38d066] 2. Change the [i:f9bd38d066]"driverName"[/i:f9bd38d066] to [i:f9bd38d066]"url"[/i:f9bd38d066] 3. Modify your database url as follows: [i:f9bd38d066]jdbc:microsoft:sqlserver://167.209.148.31:1433;databaseName=bbylab;SelectMethod=cursor;[/i:f9bd38d066]
Note that the URL ends with semicolon. Moreover, capital letters in the URL [b:f9bd38d066]do[/b:f9bd38d066] matter, hence if your database name is BByLab, modify the paramater accordingly.
You can also double check that user [i:f9bd38d066]sa[/i:f9bd38d066] identified by the given passowrd has access to the bbylab database.
Hope this helps, Michael
Subject: RE: JNDI setup Replied by: null on 09-12-2004 08:43:53 PM I tried your suggestion but it still doesn't work. I still get this error message
[quote:c7cb2bcb50]SERVER ERROR: An Audium element encountered an exception. The exception was: There was a problem looking up the JNDI data source 'java:comp/env/jdbc/test'.[/quote:c7cb2bcb50]
I wrote a simple JSP to test the connection and it works.
I've attached the updated version of server.xml for your reference. Thank you.
Subject: RE: JNDI setup Replied by: Michael Bochynski on 09-12-2004 09:27:24 PM Hi,
note that the JNDI name in your custom Java/JSP code will be different than in the Database element. Please change your JNDI name setting to "jdbc/test".
I would also suggest using the simple select qurey, such as
select COL_NAME from TABLE where ID=1
Regards, Michael
Subject: RE: JNDI setup Replied by: null on 09-12-2004 09:46:41 PM Thanks for your help. I changed the JNDI name to jdbc/test and changed the query to [code:1:60d573efaf]SELECT MfrPhoneNumber FROM RebateOfferNumber2 WHERE (OfferNumber = 99999)[/code:1:60d573efaf]
but still getting the same error. Any other ideas?
I already set the logging level to 'complete'. Is there any way to get more information about this error?
Subject: RE: JNDI setup Replied by: Michael Bochynski on 21-12-2004 09:15:36 PM Hi,
I apologize for the confusion. The correct way to set up JNDI for the Database element is to use only the name of the JDBC, without â¿¿jdbc/â¿¿ part. Hence, in your situation, the correct setting for JNDI name in the Database element would be â¿¿testâ¿¿.
Please let me know if it works for you.
Regards, Michael
Subject: RE: JNDI setup Replied by: null on 22-12-2004 03:25:22 PM It works now. Thanks for your help.
Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: