Hi, I'm trying to connect to my Oracle 10g Database
i m facing the problem of connection string, following code is that i use,
please tell me how to use the connection string for accessing the oracle
database from a remote location and from local machine, at both places i m
getting the problem. tell me how to set the server name, data sourse of a
remote server to acces tha data from a client on a diffrent machine.
I used this code:
protected Oracle.DataAccess.Client.OracleConnection con;
protected Oracle.DataAccess.Client.OracleCommand orcmd;
protected Oracle.DataAccess.Client.OracleDataReader orcreader;
private void Page_Load(object sender, System.EventArgs e)
{
string cmdQuery = "SELECT COMPANY_ID, COMPANY_Name FROM COMPANY_LIST_TEMP";
con.ConnectionString="Server=Sct-hasan;User Id=sys;Password=sa;Data
Source=TADB;";
orcmd= new Oracle.DataAccess.Client.OracleCommand(cmdQuery);
con.Open();
orcmd.Connection= con;
orcmd.CommandType=CommandType.Text;
orcreader= orcmd.ExecuteReader();
con.Close();
}
..................................................
thanx .bye