Failure to debug T-SQL or stored procedures - visual-studio-2010

Sql Server 2008 SP2
In Management Studio 2008 after setting a breakpoint on any piece of T-SQL and presssing debug button:
TITLE: Microsoft SQL Server Management Studio
------------------------------
Failed to start debugger
------------------------------
ADDITIONAL INFORMATION:
Data is Null. This method or property cannot be called on Null values. (System.Data)
------------------------------
BUTTONS:
OK
------------------------------
After pressing OK.
---------------------------
Microsoft SQL Server Management Studio
---------------------------
Unable to start program 'MSSQL:://(local)/master/sys/=0'.
---------------------------
OK
---------------------------
In Visual Studio 2010
---------------------------
Microsoft Visual Studio
---------------------------
The Transact-SQL debugging session could not be started on the remote host. Verify that the instance of SQL Server is configured to enable Transact-SQL debugging.
---------------------------
OK
---------------------------
Followed advice in other thread to apply SP2 for SQL Server 2008 without success. Server is actually (local) , don't know why Visual Studio reports it as remote.

Check that your account running the debugger is a member of the sysadmin role
Also if you are running windows firewall you need to add the ports to the rules list
check this link for more details
http://technet.microsoft.com/en-us/library/cc646024.aspx

Related

Not able to modify tables on remote SQL Server 2012 database

I have Visual Studio 2010 installed on my Windows 10 PC. My website is on a shared hosting environment and utilizes a SQL Server 2012 database.
The hosting provider doesn't have web interface to manage database so I connect from the Visual Studio 2010 itself for management purposes.
Right now I am able to connect to the database and run my website locally but when I attempt to open table definition, I get this error:
This server version is not supported. Only servers up to Microsoft SQL Server 2008 are supported
Before upgrading to Windows 10, I was able to edit/add tables from Visual Studio 2010 Server explorer but now limited to read purposes only. This Windows 10 and Visual Studio is completely fresh install with nothing kept or saved from earlier windows version. I don't remember if I installed any SQL Server 2012 tools in earlier windows for managing the database from Server Explorer in Visual Studio.
I have searched a lot and even tried installing SQL Server 2012 Express which failed. Now, I am downloading SQL Server 2012 Management Studio from the same link to see if that will work. It will download in an hour or so but I don't remember downloading it earlier so wanted to ask you what can be done.
All I want is the ability to add/modify tables of SQL Server 2012 database from Server Explorer in Visual Studio 2010. Please tell me how can that be done and which tools are required for this purpose.

Installation error sql management studio 2012

I have visual studio 2013 ultimate and windows 8.1 . I tried to install SQL Management Studio 2012 and the error occurs
The following error has occurred:
Could not write value to key \SOFTWARE. Verify that you have sufficient access to that key, or contact your support personnel.
Need help to solve this.

VS 2010 cannot see SQL Server 2012 Express

On my PC with Windows 8 there is Visual Studio 2012, SQL Server 2012 Express (x64), SQL Server 2012 (x64).
Visual Studio 2012 works perfectly with SQL Server 2012 Express and SQL Server 2012. It easily adds sqlexpress to data connections of server explorer by name .\SQLEXPRESS.
But now I'm trying to add SQLEXPRESS in Visual Studio 2010. But it cannot find it.
I thought it couldn't because of version of SQL Server 2012 Express. So I've tried to install SQLEXPR_x64_ENU (SQL Server 2008 Express), but installation stacks on "Setup Support Rules". There appears error "Performance counter registry hive consistency"
I don't know should and can I install SQL Server 2008 Express. Or the solution is somewhere else?
P.S. When I'm trying to add SQL Database Server to App_Data (asp.net mvc3) there is an error "Connections to SQL Server database files (.mdf) require SQL Server 2005 Express or SQL Server 2008 Express to be installed and running on the local computer..."
So I think I should edit register of Windows to let know Visual Studio 2010 where SQL Server Express is situated...
What are your suggestions?
Did you install Visual Studio 2010 Service Pack 1 prior to installing SQL Server Express 2012 (or at all)? See this article: http://www.formatyourbrain.com/sql-server-express-2012-visual-studio-2010/

Connecting SQL Server 2008 R2 with Visual Studio 2010

I'm trying to connect SQL Server 2008 R2 to Visual Studio 2010. It seems that the versions are not consistent, it's a little strange for me since SQL Server is 2008 and VS is 2010!!! Since I'm a new user and cant upload image here you may find a screen shot of the error here:
http://img4up.com/up2/51497019025204797538.jpg
Would appreciate if anyone can help me.
Best Regards
Instead of using "Microsoft SQL Server Database File" use "Microsoft SQL Server"
Then connect using the server address and user information.
Visual Studio 2010 installs SQL Server Express 2008 and your database was created with SQL Server 2008 R2. You'll need to upgrade to SQL Server Express 2008 R2 to open this database.
You shouldn't be using the file option if the instance of SQL Server already exists and you plan to create a persistent database there (or use an existing one). You should be selecting a proper instance of SQL Server.
Follow the same steps as iamkrillin/Stecenko Ruslan suggested., If you had provided a username and password during the installation of SQL Server R2 , then choose the radio button "Use SQL Authentication" instead of "Use Windows Authentication"., in the "Add Connection" dialog of Visual Studio 2010.

Unable to Load Database project in VS2008

I have Database project which I'm unable to load in VS2008 and I have SQL Server 2008 Express edition installed on my machine..
I get following error message, when I try to load
Database projects require a connection
to a local instance of Microsoft SQL
Server 2005 for design-time
validation. To perform this operation,
you must open the Tools menu, click
Options and specify an instance of SQL
Server 2005 that is running and to
which you can connect in the Database
Tools, Design-time Validation Database
property page. When that is corrected,
you must then refresh or reload the
database project.
Any suggestions/update to solve this issue?
You don't mention if you have VS2008 SP1 installed, but this is a requirement for SQL Server 2008 support in Visual Studio (KB956139)
Did you verify your instance name is correct? Tools > Options > Database Tools > Data Connections -> SQL server instance name: SQLEXPRESS (or the name you chose during install)
Does your instance accept remote connections? (mine always does, not sure if this is required) (Source)
I know this is an old thread, but...
Were you able to get this combination working? Visual Studio 2008 with SQL Server Express 2008? I had the same issue that no matter what I entered into the instance fields in the Tools->Options->Database Tools boxes, it said I did not have them entered.
From what I could find on the interwebs, everything indicated that SQL Server Express 2008 should work with Visual Studio 2008 as long as you have the SP1 installed. I tried reinstalling SP1, but received the same error - "no instance specified".
So I downloaded and installed SQL Express 2005 x64 and specified a new instance name, SQLEXPRESS2005. Then I plugged that into Visual Studio 2008's settings and it worked right away.

Resources