拜求SL连接ORACLE数据库的DEME

ch5201314zt 2010-07-16 06:01:03
如题,给点思路吧.
...全文
411 15 打赏 收藏 转发到动态 举报
写回复
用AI写文章
15 条回复
切换为时间正序
请发表友善的回复…
发表回复
血狼暗影 2011-05-19
  • 打赏
  • 举报
回复
哎,我又落伍了啊
地狱咆哮者 2010-07-18
  • 打赏
  • 举报
回复
看看!!!
海涵德 2010-07-18
  • 打赏
  • 举报
回复
我的分析:
实际上vs2008开发平台在silverlight解决方案中有两个项目,一个是silverlight项目,另一个是用于调试用的Web项目,Web项目是从asp.net升级过来的,先后经过vs.net、vs2003.net、vs2005.net、vs2008.net,如果只是开发asp.net当然支持ADO.net了,由此得到结论(只是分析,当然要有人调试了):wcf代码是写在Web项目中,应该可以使用ADO.net。
海涵德 2010-07-18
  • 打赏
  • 举报
回复
Private _connectionString As String = "Data Source=HAIHANDE-PC\SQLEXPRESS;Initial Catalog=madaming_database;User ID=sa;Password=madaming@nmcdl.m.1"
'把上一行改成: Private _connectionString As String = "Data Source=privider.oracle;Initial Catalog=madaming_database;User ID=sa;Password=madaming@nmcdl.m.1"
' 具体连接串记不住了,那位试试
<OperationContract()> Public Function update_student(ByVal new_student As student) As student
Dim DC As New DCMadamingDataContext(_connectionString)
Try
DC.student.Attach(new_student, True)
DC.SubmitChanges()
Return new_student
Catch ex As Exception
End Try
Return Nothing
End Function
老Key 2010-07-17
  • 打赏
  • 举报
回复
[Quote=引用 1 楼 sunpire 的回复:]
ADO.NET Entity Framework 2.0 支持 Oracle 了吧?

Silverlight本身不能连接数据库的,一般是通过WCF + ADO.NET Entity Framework/LINQ to SQL 来连接数据库。
[/Quote]就像sunpire说的那样。。你在ado.net能连接上就可以了,,sl都是调用wcf等服务去管理数据库的。。。
ch5201314zt 2010-07-17
  • 打赏
  • 举报
回复
周六没人吗?
ch5201314zt 2010-07-17
  • 打赏
  • 举报
回复
[Quote=引用 6 楼 jv9 的回复:]
可以参考这篇:

Effective EF with Oracle – RIA & Silverlight 3

http://silverlightchina.net/html/developer/2010/0716/1553.html
[/Quote]
不好意思,英文的俺看不懂啊!
海涵德 2010-07-17
  • 打赏
  • 举报
回复
[Quote=引用楼主 ch5201314zt 的回复:]
如题,给点思路吧.
[/Quote]
这是以前的一个帖子:

回复于:2010-05-28 20:26:36
如果你熟悉ADO.net,那么一定熟悉连接oracle的连接串,把下面的连接串改成连接oracle的连接串试试,从oracle 9i以后早就不用了,没有环境所以不能替你试了。

Private _connectionString As String = "Data Source=HAIHANDE-PC\SQLEXPRESS;Initial Catalog=madaming_database;User ID=sa;Password=madaming@nmcdl.mil.1"
<OperationContract()> Public Function update_student(ByVal new_student As student) As student
Dim DC As New DCMadamingDataContext(_connectionString)
Try
DC.student.Attach(new_student, True)
DC.SubmitChanges()
Return new_student
Catch ex As Exception
End Try
Return Nothing
End Function


有没有人试过我的想法?
jv9 2010-07-17
  • 打赏
  • 举报
回复
可以参考这篇:

Effective EF with Oracle – RIA & Silverlight 3

http://silverlightchina.net/html/developer/2010/0716/1553.html
jv9 2010-07-17
  • 打赏
  • 举报
回复
[Quote=引用 7 楼 ch5201314zt 的回复:]
引用 6 楼 jv9 的回复:
可以参考这篇:

Effective EF with Oracle – RIA &amp; Silverlight 3

http://silverlightchina.net/html/developer/2010/0716/1553.html

不好意思,英文的俺看不懂啊!
[/Quote]

哪里不懂,我可以解释给你听。其实都是图片,按照步骤做就可以了。
tackey86 2010-07-16
  • 打赏
  • 举报
回复
用WPF或WEB Service吧
Sunpire 2010-07-16
  • 打赏
  • 举报
回复
而LINQ to SQL 由于只是一个过渡产品,估计不会有 LINQ to Oracle 这个东东的出现。
看来只能在 WCF 中使用 ADO.NET 访问 Oracle 了,苦。
Sunpire 2010-07-16
  • 打赏
  • 举报
回复
目前还不支持,看这个链接 http://www.oracle.com/technology/tech/dotnet/col/ef/oracle_entity_framework_sod.pdf

Oracle Database Support for Microsoft® ADO.NET Entity Framework
Oracle plans to enhance Oracle Data Provider for .NET (ODP.NET) to support ADO.NET Entity
Framework. Oracle database developers will be able to use Visual Studio tools and APIs that are a standard
part of the ADO.NET Entity Framework.
ADO.NET Entity Framework is a client-side/middle-tier technology. As such, the Oracle’s client software
and ODP.NET will integrate directly with Entity Framework to support data access with the Oracle
Database.
Oracle plans to certify with ADO.NET Entity Framework with the following ODP.NET versions and
timeframes:

Software --- Timeframe (Calendar Year)
ODP.NET Beta with Entity Framework --- Around the end of 2010
ODP.NET Production with Entity Framework --- 2011

This statement of direction demonstrates Oracle’s ongoing commitment to support its .NET customers. For
latest information regarding Oracle and .NET development, check the .NET Developer Center on Oracle
Technology Network (http://otn.oracle.com/dotnet).

2010年底出Beta版,ODP.NET Beta with Entity Framework
ch5201314zt 2010-07-16
  • 打赏
  • 举报
回复
[Quote=引用 1 楼 sunpire 的回复:]

ADO.NET Entity Framework 2.0 支持 Oracle 了吧?

Silverlight本身不能连接数据库的,一般是通过WCF + ADO.NET Entity Framework/LINQ to SQL 来连接数据库。
[/Quote]
不知道啊,我用ADO.NET Entity Framework没找到方位ORACLE数据库的
silverlight本身不能访问数据库我是知道的,
我就是想要一份WCF访问ORACLE数据库的DEMO
找了很多的资料都没有找到
Sunpire 2010-07-16
  • 打赏
  • 举报
回复
ADO.NET Entity Framework 2.0 支持 Oracle 了吧?

Silverlight本身不能连接数据库的,一般是通过WCF + ADO.NET Entity Framework/LINQ to SQL 来连接数据库。

8,735

社区成员

发帖
与我相关
我的任务
社区描述
WPF/Silverlight相关讨论
社区管理员
  • WPF/Silverlight社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧