S
Saquib
Hi All,
I have built a simple .Net console application. In which i am trying
to connect to the oracle database by using Oracle data provider
for .Net from ORACLE site and it works fine on my machine. I have
installed the same on my main server but when i run this application
from Our main server i am getting an exception. The exception is as
follows.
'Oracle.DataAccess.Client.OracleException at
Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32
rrCode, OracleConnection conn, IntPtr opsErrCt
x, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure)
at Oracle.DataAccess.Client.OracleException.HandleError(Int32
errCode, Oracle
Connection conn, IntPtr opsErrCtx, Object src)
at Oracle.DataAccess.Client.OracleConnection.Open()
at TestODACWithWindows2000.Program.Main(String[] args)'
I am not able to trace out the exact cause why it is failing from that
server. While the oracle server is pingable from that server.
My application is as follows
using System;
using System.Collections.Generic;
using System.Text;
using Oracle.DataAccess.Client;
using System.Data.SqlClient;
using System.Xml;
using System.Data;
using System.Xml.XPath;
using System.Xml.Xsl;
using System.IO;
namespace TestODACWithWindows2000
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Opening........");
string ConnectionString = "Data
Source=(DESCRIPTION="
+
"(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=Host)(PORT=1521)))"
+
"(CONNECT_DATA=(SERVER=DEDICATED)(SID = SID)));"
+ "User
Id=username;Password=password;";
OracleConnection ora = new
OracleConnection(ConnectionString);
try
{
ora.Open();
}
catch (Exception ee)
{
Console.WriteLine("{0} Exception caught.", ee);
Console.ReadLine();
}
}
}
}
Please help me out.. Its urgent.
I have built a simple .Net console application. In which i am trying
to connect to the oracle database by using Oracle data provider
for .Net from ORACLE site and it works fine on my machine. I have
installed the same on my main server but when i run this application
from Our main server i am getting an exception. The exception is as
follows.
'Oracle.DataAccess.Client.OracleException at
Oracle.DataAccess.Client.OracleException.HandleErrorHelper(Int32
rrCode, OracleConnection conn, IntPtr opsErrCt
x, OpoSqlValCtx* pOpoSqlValCtx, Object src, String procedure)
at Oracle.DataAccess.Client.OracleException.HandleError(Int32
errCode, Oracle
Connection conn, IntPtr opsErrCtx, Object src)
at Oracle.DataAccess.Client.OracleConnection.Open()
at TestODACWithWindows2000.Program.Main(String[] args)'
I am not able to trace out the exact cause why it is failing from that
server. While the oracle server is pingable from that server.
My application is as follows
using System;
using System.Collections.Generic;
using System.Text;
using Oracle.DataAccess.Client;
using System.Data.SqlClient;
using System.Xml;
using System.Data;
using System.Xml.XPath;
using System.Xml.Xsl;
using System.IO;
namespace TestODACWithWindows2000
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Opening........");
string ConnectionString = "Data
Source=(DESCRIPTION="
+
"(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=Host)(PORT=1521)))"
+
"(CONNECT_DATA=(SERVER=DEDICATED)(SID = SID)));"
+ "User
Id=username;Password=password;";
OracleConnection ora = new
OracleConnection(ConnectionString);
try
{
ora.Open();
}
catch (Exception ee)
{
Console.WriteLine("{0} Exception caught.", ee);
Console.ReadLine();
}
}
}
}
Please help me out.. Its urgent.