请在以下情况下帮助我 [英] Please help me in the following scenario

查看:87
本文介绍了请在以下情况下帮助我的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有两个asp.net Web应用程序..两个网站有两个不同的sql数据库...我们必须能够访问website2中的website1数据


我该怎么做...我应该使用网络服务吗?如果可以,请告诉我确切的程序..


谢谢..

we have two asp.net web applications..two websites have two different sql databases...we must be able to access website1 data from website2

how can i do that...should i use webservices...if yes can you tell me the exact procedure..?


thanks..

推荐答案

对于这种要求,有一些选择.

1.如果两个站点都相关并且不需要任何隐私,那么您可以在两个Web应用程序中都拥有两个数据库的连接字符串.使用连接字符串,您可以检索/提交数据到两个站点.

2.如果两者都不相同,并且必须分别进行配置,则可以创建Web服务
更多详细信息 [ ^ ]
There are some options for this kind of requirement.

1. If both sites are related and no need of any kind of privacy, then you can have connection string of both the database in the both web application. With the use of connection string you can retrieve/submit data to both sites.

2. If both are different and you must have to separate configuration then you can create a web service
Many examples[^]

3. You can also create a WCF call. More Details[^]


开始^ ]. Web服务解决方案可能是将数据从一个获取到另一个的最简单方法.
Start here[^]. A web service solution is probably the easiest way to get the data from one to another.


这篇关于请在以下情况下帮助我的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆