SQL SERVER – 2008 – Fix Connection Error with Visual Studio 2008 – Server Version is not supported

While attending conference SQLAuthority Author Visit – Microsoft Student Partner Conference, some developers informed me that SQL SERVER 2008 cannot be connected to Visual Studio 2008 and error displays as MS does not support SQL Server version. I was surprised initially as I could not believe that two MS products are not compatible. When trying myself I got the same error.

SQL Server 2008 when connected to Visual Studio 2008 gives the error that “This server version is not supported.  Only servers up to Microsoft SQL Server 2005 are supported“.

This error can be easily resolved by just installing Service pack. Download Visual Studio Service Pack 1 and install. Once service pack installed it will connect just fine.

Reference : Pinal Dave (http://blog.SQLAuthority.com)

About these ads

45 thoughts on “SQL SERVER – 2008 – Fix Connection Error with Visual Studio 2008 – Server Version is not supported

  1. Thanks for Link, But there is one problem. Its download the installer in seconds, but installing needs much time, as its downloading 4GM from live site, which is I believe not good. Any other link where I can get the exe?

    Imran
    [MCTS]

  2. Hello Imran,

    I have tried to look for other link where complete SP can or other patch can be downloaded but I found none.

    If any body know solution about this please post it here.

    Kind Regards,
    Pinal

    • My name is shilton,i came across this post when surfing for solution to the same problem you encountered.how were you able to resolve the problem?i have tried alot of ways including downloading visual studio service pack 1, but am yet to get a solution to the connection error (this server version is not supported,only server version up to microsoft SQL server 2005 are supported).i will really appreciate it if you can help me on how to resolve this error.

  3. hi there!

    maybe i’ve found another issue:

    said that: debugging T-SQL SP without parameters works properly, then all the security issues etc. .. are OK.

    said that thanks in advance if you will answer ..

    said that this time I want to call into question whether some MVP is listening ..

    this is the problem and steps to reproduce the behavior:

    1. Visual Studio 2008 SP1 connected to a database that runs on SQL Server 2008 in a machine other than mine (level 8.0 compatibility, as it is plugged into a db in 2000)

    2. click on a sp with parameters (of any user defined types) and as usually select the “step into stored procedure”

    3. debugging of stored procedures does not start, and in the output appears :

    Running [dbo]. [RRintracciaDatiDaDocumentoPM31] … (@ UserName = admincapa, @ PWD = admincapa, @ IDDocumento = 262155, @ IDTestata = -1).

    Incorrect syntax near the keyword ‘SET’.
    Incorrect syntax near ‘,’.
    Incorrect syntax near ‘,’.
    Incorrect syntax near ‘,’.
    Incorrect syntax near ‘,’.
    Declare the scalar variable “@ param1″;.

    (0 rows returned)
    @ = RETURN_VALUE
    Running [dbo]. [RRintracciaDatiDaDocumentoPM31] complete.
    The thread ‘hydrogen \ idrogeno2008 [64]‘ (0xbd8) ended with code 0 (0x0).
    The program ‘[2268] [SQL] hydrogen hydrogen \ idrogeno2008′ ended with code 0 (0x0).

    Note that I did not @ None Var1 in my stored.

    so, is it a bug in visual studio??

    have a nice day!

  4. Pingback: SQL SERVER - 2008 - Fix Connection Error with Visual Studio 2008 - Server Version is not supported - VS SP1 ISO Download Journey to SQL Authority with Pinal Dave

  5. Hello sir…
    i hav installed VS2008 SP1 and SQL Server 2008 Express.
    earlier i made a project in VS2005 plus SQL 2005 and it was working fine…
    when i switched to these new versions and upgraded my project, and when i started debugging it gave me an Exception :
    A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 – Could not open a connection to SQL Server)

    i had banged my head alot on the internet and still unable to find the solution… please help me…

    Thanks

    Kinchit Arora

  6. Hi,

    I had Visual studio 2008 and I faced this issue and thus installed the SP1. But now Visual studio isnt opening for me.

    Platform:

    Visual studio is installed on Win 7.

    Thanks,
    Shruti

  7. @Shruthi,

    The best way to work with tight integration of all Dev Tools in Win7, is the following install procedure

    1) OS and IIS (If using Reporting Services)
    2) Office 2007 SP2 /2010 Tech Preview
    3) SQL Server 2008(x32,x64or IA64) + SP1
    While installing SQL Server 2008, choose everything
    4) Now install VS 2008 + Sp1

    You are good to go!

    Good Luck!

    Thanks

  8. @Kinchit,

    [Sanity Checks]

    1) Did you restart your machine after the upgrades?

    2) Did you check if the services have started in Services.msc?

    [Coding Checks]

    3) Check to see, if you can connect with your VS 2005 project to SQL Express 2008?

    4) Check if you can first connect through management studio?

    5) Finally check if you are able to establish a connection, using your App.config file, check the connection strings etc

    Hope this helps

    Thanks

  9. Anil or Pinal,

    NEW WINDOWS 7 64bit (x86 <- for 32 bit apps) .NET Visual Studio setup
    to run an originally created XP Pro 32bit .NET Visual Studio setup.

    XP Pro setup, when everything worked* ok
    – Windows XP Pro
    – Visual Studio 2008 Academic Pro upgraded to the latest
    – Ajax
    (Note: although Ajax was installed, nothing in the project
    uses it yet.)
    – SQL Server Express 2005
    – MSDE (Vale Software product to manage SQL)
    I never used the Server Explorer in Visual Studio

    (*Everything worked great until the debugger started to abort sessions after a minute or so…it worked for years and suddenly started to fail. I remember getting around that but I cannot remember what the fix was, Lately, I tried everything from a new project with minimal vanilla setups to no avail,I could never resolve that problem…)

    I decided to upgrade to WIN 7 when a hardware crash caused me to buy new equipment.

    ***** means issues left to resolve
    – Dual core 64bit box
    – WINDOWS 7 Pro (x86 <- for 32 bit apps)
    – Obviously on Pro the IIS 7 is installed, except nothing needed
    for Visual Studio is turned ON.
    I followed the blogs to turn on the appropriate entries

    ***** I need a clear list of what shoud be TURNED ON
    I have simple list for WIN XP Pro… that was easy.
    Now everything is renamed, my list is subject to translation.
    …and it seems that one must go in 2 places now:
    – the Services?
    – and the Turn windows features on/off?

    I installed in various order*:
    – Office 2003 works great so far
    – Visual Studio 2008 Pro Trial
    (Noticed that Visual Studio install, installs The 3.5 Framework
    and SQL Server 2005) <-not sure if Express or not
    – SQL Server Express 2008

    *I say in various order because, as I run into problems and follwo advice on the net… I may have installed Service Packs after the fact, etc…)

    THIS IS MESSY TO SAY THE LEAST
    Problems I ran into:

    – debugger still times out !!!!!!!!!
    ***** I suspect due to the order things were installed?

    – .js files would not come up in Visual Studio(intellisense
    problem I believed)
    after reinstallation I was able to work with .js files

    – The SQL Server Explorer sees my 2005.mdb
    I am able to change file structures, create tables,query
    and change the data

    – ***** My .NET app does not see the database

    – My MSDE(Vale Software) SQL Managment tool does not
    install on WIN 7

    In trying to get those items to work I followed the advice on the blogs to use the software that removes the Frameworks, that failed, so I ended up REINSTALLING WIN7 from the OEM CD.

    I am now at this point:
    – I have installed Office 2003 – I cannot afford Office 2007
    In the sequence of installing the software you mention Office 2007…
    **** 1. Will Office 2003 work?
    **** 2. Why is Office even mentioned, in this context?

    I want to install:
    – SQL Server Express 2008
    – *****Hopefuly I can use this tool to manage the database
    admin
    – *****and I can connect to the HOST as well to do remote
    admin and not need the MSDE product mentioned above.
    (Note: on my first attempt, I did not see options to setup
    a user in the database in SQL Explorer)

    – Visual Studio 2008 Pro Trial with Ajax

    @@@@@@@@@@@@@@@@@
    ***** I need to know what to install next in what sequence and what service pack?
    ***** …and for instance, what modules can be installed directly by using the LATEST service pack install without having to install all the previous versions?

    I will create a restore point at each install, to avoid having to reinstall WINDOWS.

    The connection string I used on my XP Pro setup:

    Note, Path: (F:\Program Files\Microsoft SQL Server\MSSQL$DOM2\Data\My2005dtabase.mdf)

    I do not know why I had to use sa versus Server Authentication?

    The connection string I am trying on WIN 7 setup

    ON WIN 7 setup, I was never able to get my .NET App to see the database no matter how many connection strings I tried.
    .

  10. Connections strings were stripped, I hope due to the brackets and slashes-backslashes, replaced here with @@@ – @

    Connection String on XP Pro Setup
    @@@ add key=”ThisConnectionString” value=”SERVER=GATEWAY@DOM2;DATABASE=My2005database;Password=xxxxxxxx;User ID=sa”@ @@@

    Connection String on WIN 7 Setup
    @@@add name=”MyProject.My.MySettings.ConnString” connectionString=”Data Source=.@SQLEXPRESS;AttachDbFilename="C:@Program Files@Microsoft SQL Server@MSSQL10.SQLEXPRESS@MSSQL@DATA@My2005database.mdf";Integrated Security=True;Connect Timeout=30;User Instance=True;Password=xxxxxxxx;User ID=sa;” providerName=”System.Data.SqlClient”@@@@

    @@@ objError.Message “An attempt to attach an auto-named database for file C:@Program Files@Microsoft SQL Server@MSSQL10.SQLEXPRESS@MSSQL@DATA@My2005database.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.” String @@@

  11. .
    I found a tool on the microsoft site called WEB PI.
    I am now using it to install everything.

    It wants to install
    – the tool itself(WEB PI)
    – IIS extensions?
    – the Framework series
    – SQL Server 2008 Express
    It recommends mixed authentication, thus what I elect.

    I cannot sit here idle, thus I have it running now.
    I hope it does not clobber the IIS 7.5 and the 3.5 Framework that are already on WINDOWS 7 Pro ?

    Will the Visual Studio 2008 Trial SP1 also reinstall the Framework?

    Keeping my fingers crossed that I may yet spend an entire day on a failed install.
    .

  12. well… disaster…
    after reinstalling everything, now i cannot create a database in SQL Server Explorer in Visual Studio.

    and if I try to point it to My2005.mdf same problem a massive error mesage:

    now, remember I was able to look at My2005database.mdf on the previous instal.

    The only thing I can asume causes this new problem is that I did a custom install of VS2008 and checked off the install of SQLServer 2005… since I installed SQL Server 2008!!!

    I am going to try to overlay 2005 now by doing a repair in VS install… but I think I will waste me time yet, again.

    Going to this new system for me is a disaster. I was fine in the Previous XP setup, i could copy any database in the SQL$.xxxx folder and I was good to go…

  13. ALL THESE ERRORS cannot be cut & pate, one must painfully retype them

    Here is the first error I got:

    A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider,
    error: 40 – Could not open a connection to SQL Server)

  14. sir i had installed visual studio 2008 and when i am creating an database it is giving me an error that connection microsoft sql server express edition.I dont know what to do.Please i need ur help.

  15. Hey,
    I saw your articals(Which I love) and had the same problem but I install the SP and it’s didn’t help… what can I do?
    Thank you,
    btw – It’s the first time that I install SQL Server (2008) and visual studio (2010) on this computer…
    Shirly

  16. hi sir, I first installed visual studio then i installed IIS server . when i created new web site it’s showing like this
    “Configaration website “http:…..” failed.you must manually configure…..” so in executed “%windir%\Microsoft.NET\Framework\v2.0.50727\aspnet_regiis -i” this commed cmd prompt.

    but when debuging asp.net application i am not getting output on web browser it showing “server error ”
    pls help me sir ..

  17. HI SIR,

    I HAD INSTALLED VISUAL STUDIO 2010,AND SQL SERVER 2008,THE VISUAL STUDIO IS WORK,BUT I AM UNABLE TO CONNECT TO SQL SERVER 2008 IN BOTH WINDOWS AND SQL SERVER AUTHENTICATION MODES.PLEASE HELP ME TO CONNECT TO THE MODES.

  18. windows 7 64 bit

    Adventureworks_data.mdf is located in
    C:\Program Files (x86)\Microsoft SQL Server\MSSQL.1\MSSQL\Data

    not which is reserved for 64 bit applications
    C:\Program Files\Microsoft SQL Server

  19. Having an issue with SQL server 2008 R2

    Getting this error “This server version is not supported.Only Up To Microsoft SQL server 2005 are supported” after I create a data connection in Visual Studio 2008 SP1 and SQL server 2008 R2. Any ideas would be great.

    No other version of SQL server Installed.

    The error occurs after I select server, then database. Just as I click OK I get that message.

  20. Thanks VERY MUCH! I have VS 2008 and VS 2010 installed, was really not looking forward to troubleshooting with multiple installations.

    I appreciate this post, will try to remember it in case my student and programming peers run into this problem.

  21. Hi,

    I experienced the posted issue, and downloaded and installed the service pack. When trying to add SQL server connection from the Server Explorer,I got the following error:
    Unable to add data connection .
    The IDBToolsOptionProvider service could not be found.

    I cannot find information about this service.

    Can you please help?

    Thanks,
    Shani

  22. Hi,

    I experienced the posted issue, and downloaded and installed the service pack. When trying to add SQL server connection from the Server Explorer,I got the following error:
    Unable to add data connection .
    The IDBToolsOptionProvider service could not be found.

    I cannot find information about this service.

    Can you please help?

    Thanks,
    Shani

    (Added e-mail notification)

  23. You ROCK man, never seen any one mastering SQL like you before.

    I am a developer, Whenever face any SQL issue and end up in your pages I assure a sigh of relief for myself. I m not surprised today, bcoz this is not the first time ur platinum suggestions have helped. Your suggestions help me without getting much into the details and that is the key for me. For a regular DB guy, it is a tiny thing may be but for the aliens like we developers, it is a nightmare. Bow to the TRUE SQL guru.

  24. I get the same message in visual web developer 2008 express “this server version is not supported only servers up to microsoft sql server 2005 are supported”

    any help

  25. Hi
    I was previously working on Visual studio 2010. which was having sql server 2008.
    but now i want to switch myself to sql server 2005 and want to use Visual studio 2008 with .net framework 2.0.

    I installed VS2008(didnt uninstall 2010). but when i try to add database.mdf file in my web application an error occurs which say

    “This server version is not supported. Only servers up to Microsoft SQL server 2005 are supported “…

    I did check at the time of installation of VS2008 that the setup was installing MS SQL SERVER 2005…

    Later i uninstalled VS2008 and VS2010 and reinstall VS2008 and created a new website and try to add database.mdf file but still same problem occurs…..

    please, Tell me what should i do…

  26. HI
    SIR
    i have problem while establish a connection,whenever i used to create database it give an error i.e-

    “A network-related or instance specific error occurred while establishing a connectiob to SQL server,the sever was not accessable verify that the instance name is correct and that SQL server is configured to allow remote connections”

    plz help me……..

  27. I have a problem while connecting SQL Server, even after entering localhost\SQLEXPRESS it is showing an error-
    “Login failed for user ‘-‘.The user is not associated with a trusted SQL Server Connection.”
    Can u plz tell me whats the problem?

  28. sir i already downloaded your SP1 upgrade that you recommended but still the error still remains, what should i do??

  29. hello sir….. when i tried to connect service-base database it shows a error msg that” login failed for user “bhandari\vipin”… plz help me how i can fixed thet problem.. im using win8 and vs 10 and sql 2008

  30. This worked for me.

    Open VS | Tools | Connect to Database | Microsoft SQL Server
    Change the Data Provider from .NET Framework Data Provider for SQL Server to .NET Framework Data Provider for OLE DB
    Leave the “Always use this selection” checked and click Continue.
    This allows me to connect from VS2008 to SQL 2012 box.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s