如何在C#中设置可以在未安装SQL Server的其他计算机上执行的SQL Server Databse应用程序写程序? [英] How to make setup of a SQL Server Databse application writtern in C# that can be executed on different machine having SQL Server not installed ?

查看:289
本文介绍了如何在C#中设置可以在未安装SQL Server的其他计算机上执行的SQL Server Databse应用程序写程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经创建了一个用C#编写的SQL Server数据库应用程序.我只想进行设置,使其可以在其他计算机上运行.我想问问有可能吗?

如果可能的话,那怎么办呢?

Visual Studio中是否有任何代码或内置库,以便我可以使用它来恢复我的问题.

望着您的早日答复.

问候,

Mushtaq Ali

I have created a SQL Server database application written in C#. I just want to make a setup so that it can run on different machine. I want to ask that is it possible or not?

If it is possible, then how it can be done?

Is there any code or built-in Library in Visual Studio so that i can use it to recover my problem.

Looking froward your early reply.

Regards,

Mushtaq Ali

推荐答案

您可以在SQL Server上启用远程连接,并且安装应用程序的所有计算机(如果它们是相同或相同的网络)都可以连接到它.否则,您也可以通过Internet连接到SQL Server.
You can enable remote connections on your SQL server and all the computers where you install your application can connect to it if they are or same network. Or else you can also connect to SQL server through internet.


您还可以使用SQL Server CE在用户计算机本地安装数据库.但是,这与SQL Server 2005(以及2000和2008)略有不同. SQL Server CE类似于SQL Server,但是它没有那么多功能(例如,它没有存储过程).

否则,您需要将数据库放在可以从安装应用程序的所有计算机上访问的计算机上.请记住,您作为开发人员使用的本地连接字符串可能与远程使用(每个用户使用的连接字符串)不同.
You can also install a database locally to the user''s computer using SQL Server CE. However, that is a little different than SQL Server 2005 (and 2000, and 2008). SQL Server CE is like SQL Server, but it doesn''t have as many features (e.g., it doesn''t have stored procedures).

Otherwise, you need to put the database on a machine that can be accessed from all the computers you are installing your application on. Keep in mind that your local connection string (that you use as a developer) may not be the same as the connection string you use remotely (that each user uses).


这篇关于如何在C#中设置可以在未安装SQL Server的其他计算机上执行的SQL Server Databse应用程序写程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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