Is it possible to revert file open behavior of SSMS 16.* to the SSMS 2012 behavior? - ssms-2016

SSMS 2012 used to open a script from shell integration in a new tab, re-using the session to the currently selected DB in the explorer, or the current tab's session.
The new version opens an entire new instance where I have to make a new connection to the DB.
Is it possible, through a registry hack or other means, to revert this behavior to what SSMS 2012 used to do?

SSMS 17.3 reverted that behavior - upgraded and it's fine now.

Related

Not able to create Database project in Visual Studio 2019

I have worked 2 months ago on the database project using Visual Studio. All went fine. Now I am back to it again but this time I am unable to create a connection. I am kind of loop where I get a popup window to enter the database connection information when I am importing a database and once I enter the connection information I am back to same screen requiring the same information.
I checked the database version and I found that it was recently updated to "Microsoft SQL Azure (RTM) - 12.0.2000.8 Apr 18 2022". So seem like that is the issue of compatibility. I updated my Visual Studio to version 16.. and tried again. but I still find the issue. Just to check other options I got the VS22 and it did work fine however, I am not allowed to use VS22 and I suppose VS2019 should work somehow.
So anyone can guide me to revolve that issue.

Visual Studio SSIS Variable Window not displaying not working as expected

I have 2019 VS with SSIS installed. For some reason, the variable window is no longer allowing me to see the existing variables nor create new variables. Below is the window of the variable when I open it.
I experienced the same problem, and remedied it by installing the SQL Server Integration Services Projects update as recommended by the Developer Community.
https://developercommunity.visualstudio.com/content/problem/581038/ssis-variables-window-is-transparent-in-vs-2019-16.html

TFS in Visual Studio and SQL Server Management Studio

I got a project which includes both a windows service (a C# project/solution in VS2013) and some SQL scripts (a SQL Server Script project/solution in SSMS 2012).
Both of these use TFS as source control.
The strange thing is that pending changes differ between VS and SSMS.
In SSMS I only see changes to files in the SSMS solution.
In VS I see all changes in both solutions except new files added to the SSMS solution.
This means I can't check in all changes in one place and have them in one change set (unless I manually add the new SSMS files in the VS Source Control Explorer).
I am pretty new to TFS (coming from Mercurial/Git) so I still don't understand how many things work, e.g. how pending changes/source control explorer detect new files.
If you are using TFS 2012 or later, you can choose either a local or server workspace from within VS. There are pros and cons to each but with the local workspace you should be able to achieve this requirement. Visual Studio will detect new files that is within it's source control and add/edit/delete as a pending change as required.
What version of TFS are you using?

Missing Server Explorer right-click menu options in Visual Studio 2010

I've searched high and low for the answer to this and can find nothing on it. I have installed VS 2010 pro edition on a virtual machine running MS XP Pro. After connecting to my database, I can see all the tables, stored procedures, and functions just fine in the list. However, when I rick-click on any of them, the options to create new/edit/run any of them are missing.
This is not the first time I've set up VS 2010. I got a new laptop so reinstalled everything. I changed no settings the first time I've set this up, and none this time. I set up the connection to the databases the same way each time, and even looked at my old connection settings while I set up this installation. The old installation had all of the right-click options, but this one does not. I have tried going to Tools -> Import and Export Settings -> Reset all settings and tried General Development Settings, Visual C# Development Settings, and Web Development as the default collection of settings. None of these worked.
I've looked through the settings and found nothing for the right-click menu. It almost seems as if the database connection is open in a "read only" mode, but there doesn't seem to be a setting for that, so I don't think that is the case. If anyone knows of any way to get these options to show up, I would greatly appreciate the input. Thanks in advance.
After I installed Visual Studio 2010 (Ultimate), I accidentally uninstalled the SQL Server Data Tools which were installed together with VS, and after reinstalling them (by repairing the VS installation) the missing context menue options were back again.
Desperate to resolve this, I played around with the connection more. I had originally chosen Microsoft SQL Server as the data source, and .NET Framework Data Provider for OLE DB as the Data Provider. Evidently, the data provider was wrong. After choosing .NET Framework Data Provider for SQL Server, it worked and I could see all of my right-click menu options.
I have VS 2013 Ultimate installation. Along this version I installed SSTD BI. Everything was working perfect until I got the same issue. Right-click on tables or other folders displays only three options: copy, refresh, property. The tricky thing is that it's impossible to uninstall SSTD BI in Control Panel or install SSTD BI on top of previous installation. What helped me is repair installation of VS2013. Start your installation file and chose repair instead of installation. Couple hours and it's back to work.
I downloaded SSTD from here and it fixed my missing context menus
https://msdn.microsoft.com/en-us/mt186501

Change Ssms2008 default setting on installation

Hey, I am currently developing a vbs script, which installs SQL server 2008 + SP1. After the install I want to change the default settings in the Ssms, such as "Prevent saving changes that require table recreation" and such on.
I can't figure out, where Ssms hides its settings. Currently I am looking at
1) My Documents\SQL Server Management Studio\
2) HKCU\Software\Microsoft\Microsoft SQL Server\100\Tools\Shell\Profile
But whenever I change a "setting" in the vssettings-file in 1), Ssms thinks it is first time it runs, and overwrite.
How can I change the Ssms setting manual, without doing it from the Ssms itself?
Unfortunately, on first run SSMS has to rebuild configuration information, since that is the way VSShell is designed and SSMS2005 - SSMS2008R2 is built on a top of VS Shell.
I'm not 100% sure, but you can try to run SSMS /setup (runs without UI), that theoretically should trigger that rebuild.
SSMS stores settings in multiple places. Most of Tools->Options settings are stored in "C:\Users\\AppData\Roaming\Microsoft\Microsoft SQL Server\100\Tools\Shell\SqlStudio.bin"
Which is binary serialization of the settings structure.
But if you reference "C:\Program Files (x86)\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\Microsoft.SqlServer.Management.UserSettings.dll" assembly, you can access it programatically:
Console.WriteLine(Settings<SqlStudio>.Current.SSMS.Startup);
Settings<SqlStudio>.Save(true);
Please note, that this file doesn't exists right after installation, but if you instantiate the Settings object ans call Save method, it will be created and used.

Resources