问题描述
我有一个SQL Server DB,可以使用SSMS手动附加它,此后应用程序可以正常工作.我想使该过程自动化,即不希望我的客户端使用SSMS附加数据库,但我希望我的应用程序在首次运行或安装过程中执行该操作.但是我完全不知道该怎么做.许多人建议使用代码段,但我不知道将代码段放在何处.
我已经看到了SQLDMO的概念,但是在vb.net上找不到Google如何制作和使用它们.
有人能帮我吗?
感谢
Hi,
I have a SQL Server DB which I can attach manually using SSMS and application works fine after this. I want to make the process automatic, i.e do not want my clients to use SSMS to attach DB but I want my application to do it at first time run or during installation. But I have no idea at all how to do it. Many people suggested code snippets but I donot know where to put them.
I have seen a concept of SQLDMO but could not find over google how to make and use them in vb.net.
Could any body give me some help on it?
Thanks
推荐答案
这篇关于创建数据库或将数据库附加到SQL Server实例的概念的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!