.net and oracle
来源:互联网 发布:山东卫视网络直播 编辑:程序博客网 时间:2024/05/17 07:12
c#
using System.Data.OracleClient;
try
{string strconn = "Data Source=bb;Persist Security Info=True;" +
"User ID=SCOTT;Password=xxx;Unicode=True";
//bb是net manager中的【服务命名(サービス・ネーミング)】的名称
OracleConnection conn = new OracleConnection(strconn);//conn.Open();
string sql = "select * from emp";
OracleDataAdapter oda = new OracleDataAdapter(sql, conn);
DataSet ds = new DataSet();
oda.Fill(ds);
this.GridView1.DataSource = ds.Tables[0].DefaultView;
this.GridView1.DataBind();
//conn.Close();
}
catch (Exception ex)
{
Response.Write(ex.Message.ToString());
}
VB.net
Dim strConn As String = "Data Source=bb;Persist Security Info=True;" +
"User ID=SCOTT;Password=xxx;Unicode=True"
Dim conn As OracleConnection = New OracleConnection(strConn)
Dim strSQL As String = "select * from emp"
Dim ds As DataSet = New DataSet()
Dim sda As OracleDataAdapter = New OracleDataAdapter(strSQL, strConn)
sda.Fill(ds, "Table")
GridView1.DataSource = ds.Tables(0)
GridView1.DataBind()
0 0
- .net and oracle
- [Oracle Client and Net Service]Oracle Client安装及Net Service的配置
- Advanced Data Access with ADO.NET and Oracle
- Oracle Net Services - Tracing and Logging at a Glance
- Oracle net
- Professional ADO.NET 2: Programming with SQL Server 2005, Oracle, and MySQL by Wallace B. McClure
- Professional ADO.NET 2: Programming with SQL Server 2005, Oracle, and MySQL
- .NET Padding Oracle Attack, padBuster.pl, and the Microsoft Recommended Workarounds
- oracle bitmap and /and equal
- OPD.NET Developer's Guide: Oracle Database 10g Developement with Visual Studio 2005 and the Oracle D
- oracle database and instance and oracle SID
- oracle and oracle seucirty information
- NET and XML-------------转贴
- C#and VB.net
- Rainbow and asp.net
- NET and XML
- flash and .net
- 调侃java and .net
- 云计算,不仅仅是数据的存储计算,更应该是数据的分析、挖掘计算- 电饭锅产业技术路线图发布:明晰发展方向
- 对外部函数的声明要注意
- u盘安装Fedora-19-x86_64-DVD.iso
- JAVA SE---基础(2)
- nyoj42 一笔画问题
- .net and oracle
- MongoDB程序开发之使用Java驱动
- 我自己建了一个个人博客网站,欢迎大家访问,后续功能还在添加之中
- 我的2013,这一年,我大三了(没有伞的孩子,更要拼命奔跑)
- 高通推近距离位置定位技术,精度可达0.3米左右
- C# WPF双击控件创建新窗口的相关问题
- 巨头公司积极吸纳自媒体
- android的edittext输入内容控制问题
- JAVA 考试准备笔记 7