Oracle Connection String problem
921940Mar 8 2012 — edited Mar 14 2012HI all,
I have Oracle 11g R2 and VS 2008 on my system. I have also installed Oracle Data Access ODAC client which I downloaded from http://www.oracle.com/technetwork/topics/dotnet/utilsoft-086879.html
I have added the Oracle Connection string in my asp.net Web.config.xm file which is:
<add name="OracleConnectionString" connectionString="Data Source=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=PRJUSER)));User Id=PRJUSER;Password=password;" providerName="Oracle.DataAccess.Client"/>
Also added a Data Connection in the VS.. I used the source below as the Data Source Name:
(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=PRJUSER)))
and this below as the Connection Name:
LASUSR.(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SERVER=DEDICATED)(SERVICE_NAME=PRJUSER)));User Id=PRJUSER;Password=password;
I tested the connection and it says Test Connection Succeeded. So the data connection was added and seem to be no issues here as it had all the tables I needed. However, I am facing an exception whenever I debug the website:
Project 'OracleConnectionString' is already added。 (C:\PRJUSER\PRJUSER\web.config line 51)
Any idea why this is happening? Thanks in advance!~
Edited by: Vicky on 2012/3/8 下午 6:52