ssms

SSMS Change Connection for Query Editor Window

折月煮酒 提交于 2019-12-03 10:01:33
Normally when I want to change the connection for a Query Editor Window in SQL Server Management Studio, I can select a new connection from the menus at the top - Query > Connection > Change Connection . However, when I am working on cubes with an analysis services connection - and then open a saved SQL script (such as the underlying SQL view) the Available Databases combobox is blank, and the "Change Connection" and other 3 options in that menu (Connect, Disconnect, Disconnect all queries) are all greyed out. The only workaround I have found to be able to run the saved SQL script, is to open

Insert new records only into SQL Table Using VBA

别说谁变了你拦得住时间么 提交于 2019-12-03 09:40:52
问题 I have an Excel workbook with the below code - Sub Button1_Click() Dim conn As New ADODB.Connection Dim iRowNo As Integer Dim sFirstName, sLastName As String With Sheets("Sheet1") 'Open a connection to SQL Server conn.Open "Provider=SQLOLEDB;" & _ "Data Source=server1;" & _ "Initial Catalog=table1;" & _ "User ID=user1; Password=pass1" 'Skip the header row iRowNo = 2 'Loop until empty cell in CustomerId Do Until .Cells(iRowNo, 1) = "" sFirstName = .Cells(iRowNo, 1) sLastName = .Cells(iRowNo, 2

SSMS SQL SERVER Management Studio 2012 startup freeze

时光怂恿深爱的人放手 提交于 2019-12-03 09:26:29
I have a strange situation. IT installed SSMS on my laptop and it runs well the first time, connected to my SQL servers remotely etc. But then it's frozen. I forced quit and then started SSMS again. Now it's totally frozen, no popup window at all to enter the server-connection text string. Then I did a force quit and got a pop up window ( see it here ). Microsoft SQL Server Management Studio has detected that an operation is blocking user input. This can be caused by an active modal dialog or a task that needs to block user interaction. Would you like to shut down anyway? Has anyone seen this

problem with trying to create ssms add-in

谁说我不能喝 提交于 2019-12-03 08:48:13
I'm trying to create an add-in for SSMS 2008 and/or 2008 R2 but I've run into a problem straight away. I can get my add-in to work and on SSMS start-up get it to simply show a message box. However, after downloading various code-samples, when trying to reference Microsoft.SqlServer.Management.UI.VSIntegration.ServiceCache I get a null reference exception: Commands2 commands = (Commands2)ServiceCache.ExtensibilityModel.Commands; I get this problem when using SSMS 2008 or SSMS 2008 R2. I'm working on Visual Studio 2010. It's a bit frustrating because I'm keen to learn more about SSMS add-ins but

How to extract MSSQLServer database as .dacpac without VerifyExtraction?

我是研究僧i 提交于 2019-12-03 08:33:16
问题 I want to extract a database schema of a MSSQLServer database with Server Management Studio. I use the Extract command "Extract Data-tier Application.." In the database are several references to another database. Because of this I get the following error. Error extracting database: Validation of the schema model for data package failed. Error SQL71562: Error validating element [dbo].[x] has an unresolved reference to object [dbo].[y]. External references are not supported when creating a

Can I use SQL Server Management Studio 2005 for 2008 DB?

半世苍凉 提交于 2019-12-03 08:26:24
问题 I am looking to manage a SQL Server 2008 DB using Management Studio 2005. The reason for this is because our server is a 64-bit machine and we only have the 64-bit version of the software. Is this possible? How about managing a SQL Server 2005 DB using Management Studio 2008? 回答1: UPDATE: You can use Cumulative update package 5 for SQL Server 2005 Service Pack 2 to connect to 2008. FIX: 50002151 946127 (http://support.microsoft.com/kb/946127/) FIX: You may experience problems when you use SQL

How to create extension for SQL Server Management Studio 17 in C# in VS2017?

痞子三分冷 提交于 2019-12-03 07:59:27
问题 I followed simple Hello World sample from Create your first extension: Hello World example from the Microsoft Docs to build an extension for SSMS 2017 Created VSIX project from Extensibility project template Changed "Start External Program" in Project > Properties > Debug to C:\Program Files (x86)\Microsoft SQL Server\140\Tools\Binn\ManagementStudio\Ssms.exe Add -S (localdb)\MSSQLLocalDB -d sampleDB -E in command line arguments as it requires servername/database be specified to run SSMS.exe.

Are there Free SQL Server Mgmt Studio Autocomplete Add-ins?

孤人 提交于 2019-12-03 07:26:00
I know Red Gate has such a product, but I'd rather not have to pay for something which, in my opinion, should be built into SSMS. Thanks! I totally agree with you on this. Sadly I never found any plugins that you are talking about. So, I moved to tools from EMS SQL Server Manager and TOAD for SQL server. I think the SQL Server 2008 Studio has intellisense but in the express edition, i found it to be seriously lacking. I’m using ApexSQL Complete . It’s quite good for a free add-in but I’ve found it has some issues working with linked server. Aqua Data Studio is free if you develop for

Insert new records only into SQL Table Using VBA

与世无争的帅哥 提交于 2019-12-03 07:18:05
I have an Excel workbook with the below code - Sub Button1_Click() Dim conn As New ADODB.Connection Dim iRowNo As Integer Dim sFirstName, sLastName As String With Sheets("Sheet1") 'Open a connection to SQL Server conn.Open "Provider=SQLOLEDB;" & _ "Data Source=server1;" & _ "Initial Catalog=table1;" & _ "User ID=user1; Password=pass1" 'Skip the header row iRowNo = 2 'Loop until empty cell in CustomerId Do Until .Cells(iRowNo, 1) = "" sFirstName = .Cells(iRowNo, 1) sLastName = .Cells(iRowNo, 2) 'Generate and execute sql statement ' to import the excel rows to SQL Server table conn.Execute

Sql Server Management Studio closes immediately after startup

萝らか妹 提交于 2019-12-03 06:30:51
问题 Sql Server Management Studio closes in about five seconds after startup. No messages are being displayed (even in a console) and no logs occur in a Windows Event Viewer. I have tried to install different SSMS versions , i.e. 16.X, 17.Y, but it have not helped. I have also tried to repair VS 2017 and SSMS. This problem occured for the first time, when I unistalled Visual Studio 2015 and its related components, like SSMS, and installed VS 2017 and newer version of SSMS (16.X). What can I do to