///这是一个ORACLE 连接数据库存的例子
string connstr="Data Source=fonny;user=scott;password=tiger";
OracleConnection conn=new OracleConnection(connstr);
OracleDataAdapter oda=new OracleDataAdapter("select * from DEPT",conn);
DataGrid dg=new DataGrid();
DataTable dt=new DataTable();
oda.Fill(dt);
dg.DataSource=dt;
dg.DataBind();
this.Controls.Add(dg);
string connstr="Data Source=fonny;user=scott;password=tiger";
OracleConnection conn=new OracleConnection(connstr);
OracleDataAdapter oda=new OracleDataAdapter("select * from DEPT",conn);
DataGrid dg=new DataGrid();
DataTable dt=new DataTable();
oda.Fill(dt);
dg.DataSource=dt;
dg.DataBind();
this.Controls.Add(dg);