Wednesday, July 29, 2015

How to create run command shortcut for opening visual studio when we have more than one version installed?

shortcut to open visual studio:-
Open Run command box(press windows + R).
Type devenv in the box and press enter.


By default it will open the visual studio you installed first in the machine.
What we need to do if we have more than one version of visual studio installed in that machine?
Here is the solution.

1) Open windows registry (regedit.exe)
2) Navitage to HKEY_LOCAL_MACHINE >> SOFTWARE >> Microsoft >> Windows >> Currentversion >> App Paths >> devenv.exe


Change the Default key to the desired visual studio devenv.exe.
This will not solve the problem fully to open different versions, then add new key and give different name just like below.

Friday, August 30, 2013

Database deployment problem in Visual Studio 2010

Problem: The reference to external elements from the source named 'msdb.dbschema' could not be resolved, because no such source is loaded.

Fix:  Closed the solution and re-started visual studio and everything worked perfectly.

Wednesday, June 26, 2013

Windows Service stuck in "stopping" state.

Most of the people often face this issue. After clicking on stop link it may stuck in "Stopping" state. One temporary solution for this problem is rebooting the machine. But it can't be possible to reboot the machine always.
Here is an alternate for the same. 1) Open "Task Manager". 2) Click on "Show processes from all users". 3) Right click on the service process and then click "End Process Tree" ( Be careful this will stop all associated child processes and background processes as well).

Monday, October 1, 2012

Unable to open .sql files in visual studio IDE or Patch update to visual studio causing issues.

Problem 1:- After installation of some add-on's to visual studio, there may be chance for getting below type of errors for ex: After installation of visual studio 2010 service pack 1 one can get these errors.

1) The 'VSTS for Database Professionals Sql Server Data-tier Application' package did not load correctly.

2) The 'RadLangSvc.Package, RadLangSvc.VS, Version=10.0.0.​0, Culture=neutral, PublicKeyToken='package did not load correctly'.

3) The "Language Package" package did not load correctly.

Problem 2:-

unable to open .sql files or sql scripts from visual studio IDE, by cling on .sql file it throws "object reference not found" error.

Solution/Fix:-

Goto visual studio installation media either through disk or hard drive media locate below 3 files and install it.

DACFramework_enu.msi

DACProjectSystemSetup_enu.msi

TSqlLanguageService_enu.msi

Thursday, May 10, 2012

Join in Update query - sql server

Simple join in update query is as follows,
 
 UPDATE T1 SET T1.Name = T2.Name
 FROM TableName T1
 JOIN TableName T2
 ON T1.Id = T2.Id
 WHERE T1.Name IS NOT NULL