I'm working in a project related to databases and I'm using a server with SQL server 2008 installed, but I'm working remotely from the office where I'm developing the software that will work with the database in VS 2015, which has built-in SQL tools to create databases, queries and so on, I have seen some tutorials where people have both VS and SSMS installed to work.
我在一个与数据库相关的项目中工作,我正在使用安装了SQL Server 2008的服务器,但是我正在办公室远程工作,我正在开发可以在VS 2015中使用数据库的软件,有内置的SQL工具来创建数据库,查询等等,我已经看到一些人们同时安装了VS和SSMS的教程。
My questions are simple: is it really needed? whats the difference in creating the DB in VStudio vs SSMS?
我的问题很简单:它真的需要吗?在VStudio和SSMS中创建数据库的区别是什么?
1 个解决方案
#1
0
You sure can. See the following tutorial.
你确定可以。请参阅以下教程。
To my knowledge there is no difference between using VS and SSMS, it is probably personal preference. For example, application developers who need to create a database probably prefer the familiarity of VS as well as keeping the DB file within their solution for code checking and what not. DB developers probably prefer SSMS because it is more intuitive and the UI is built around creating and managing databases.
据我所知,使用VS和SSMS没有区别,这可能是个人偏好。例如,需要创建数据库的应用程序开发人员可能更喜欢熟悉VS以及将DB文件保留在其解决方案中以进行代码检查,而不是。数据库开发人员可能更喜欢SSMS,因为它更直观,UI是围绕创建和管理数据库构建的。
I recommend using SSMS for creating databases.
我建议使用SSMS来创建数据库。
Update: If you want to load data into SQL Server using Visual Studio, then you accomplish this with SQL Server Integration Services (SSIS). This is a big subject and I am not aware of how well versed you are in it, but to summarize, you will need the following:
更新:如果要使用Visual Studio将数据加载到SQL Server,则可以使用SQL Server Integration Services(SSIS)完成此操作。这是一个很大的主题,我不知道你是多么精通,但总而言之,你需要以下内容:
1.) Install SQL Server Data Tools, which contains the Visual Studio templates for creating the following three project types: SSIS, SSRS, SSAS,
1.)安装SQL Server数据工具,其中包含用于创建以下三种项目类型的Visual Studio模板:SSIS,SSRS,SSAS,
Where: I = Integration; R = Reporting; and A = Analysis
其中:I =整合; R =报告;和A =分析
You can download SSDT for free at: https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt
您可以免费下载SSDT:https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt
2.) Create an SSIS solution that loads your files. There are many steps to accomplish this, but a cursory check for SSIS file loaders online yielded the following:
2.)创建一个加载文件的SSIS解决方案。有很多步骤可以完成此任务,但在线粗略检查SSIS文件加载器会产生以下结果:
One thing to note that is not contained in the above tutorial is that the versioning requirements of SSDT, VS, and SQL Server are nothing short of maddening. However, Microsoft seems to have tried to address this with VS2015 and up by allowing for SQL Server package targeting (I do not have VS2015 to confirm, I am using VS2017 and confirm that version). Once you create a solution, do the following:
有一点需要注意的是,上面的教程中没有包含SSDT,VS和SQL Server的版本控制要求,这简直令人抓狂。但是,微软似乎试图通过允许SQL Server软件包定位来解决VS2015及其问题(我没有VS2015确认,我正在使用VS2017并确认该版本)。创建解决方案后,请执行以下操作:
1.) Right click on the project
1.)右键单击该项目
2.) Click on Configuration Properties
2.)单击“配置属性”
3.) Set the TargetServerVersion to the version of SQL Server that you are running.
3.)将TargetServerVersion设置为您正在运行的SQL Server版本。
4.) Note: the components that are available in the toolbox will change - this is normal.
4.)注意:工具箱中可用的组件将发生变化 - 这是正常的。
See the following SO post for this (read billinkc's answer): VS2013 not picking up SQL2012 SSIS Custom Components
请参阅以下SO帖子(阅读billinkc的答案):VS2013没有拿起SQL2012 SSIS自定义组件
#1
0
You sure can. See the following tutorial.
你确定可以。请参阅以下教程。
To my knowledge there is no difference between using VS and SSMS, it is probably personal preference. For example, application developers who need to create a database probably prefer the familiarity of VS as well as keeping the DB file within their solution for code checking and what not. DB developers probably prefer SSMS because it is more intuitive and the UI is built around creating and managing databases.
据我所知,使用VS和SSMS没有区别,这可能是个人偏好。例如,需要创建数据库的应用程序开发人员可能更喜欢熟悉VS以及将DB文件保留在其解决方案中以进行代码检查,而不是。数据库开发人员可能更喜欢SSMS,因为它更直观,UI是围绕创建和管理数据库构建的。
I recommend using SSMS for creating databases.
我建议使用SSMS来创建数据库。
Update: If you want to load data into SQL Server using Visual Studio, then you accomplish this with SQL Server Integration Services (SSIS). This is a big subject and I am not aware of how well versed you are in it, but to summarize, you will need the following:
更新:如果要使用Visual Studio将数据加载到SQL Server,则可以使用SQL Server Integration Services(SSIS)完成此操作。这是一个很大的主题,我不知道你是多么精通,但总而言之,你需要以下内容:
1.) Install SQL Server Data Tools, which contains the Visual Studio templates for creating the following three project types: SSIS, SSRS, SSAS,
1.)安装SQL Server数据工具,其中包含用于创建以下三种项目类型的Visual Studio模板:SSIS,SSRS,SSAS,
Where: I = Integration; R = Reporting; and A = Analysis
其中:I =整合; R =报告;和A =分析
You can download SSDT for free at: https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt
您可以免费下载SSDT:https://docs.microsoft.com/en-us/sql/ssdt/download-sql-server-data-tools-ssdt
2.) Create an SSIS solution that loads your files. There are many steps to accomplish this, but a cursory check for SSIS file loaders online yielded the following:
2.)创建一个加载文件的SSIS解决方案。有很多步骤可以完成此任务,但在线粗略检查SSIS文件加载器会产生以下结果:
One thing to note that is not contained in the above tutorial is that the versioning requirements of SSDT, VS, and SQL Server are nothing short of maddening. However, Microsoft seems to have tried to address this with VS2015 and up by allowing for SQL Server package targeting (I do not have VS2015 to confirm, I am using VS2017 and confirm that version). Once you create a solution, do the following:
有一点需要注意的是,上面的教程中没有包含SSDT,VS和SQL Server的版本控制要求,这简直令人抓狂。但是,微软似乎试图通过允许SQL Server软件包定位来解决VS2015及其问题(我没有VS2015确认,我正在使用VS2017并确认该版本)。创建解决方案后,请执行以下操作:
1.) Right click on the project
1.)右键单击该项目
2.) Click on Configuration Properties
2.)单击“配置属性”
3.) Set the TargetServerVersion to the version of SQL Server that you are running.
3.)将TargetServerVersion设置为您正在运行的SQL Server版本。
4.) Note: the components that are available in the toolbox will change - this is normal.
4.)注意:工具箱中可用的组件将发生变化 - 这是正常的。
See the following SO post for this (read billinkc's answer): VS2013 not picking up SQL2012 SSIS Custom Components
请参阅以下SO帖子(阅读billinkc的答案):VS2013没有拿起SQL2012 SSIS自定义组件