When a SQL file will not open in SSMS

  • Odd, I have no entries in SSMS Tools, Options, Text Editor, File Extension and .sql files open fine....

    XP SP 3 on the workstation, with SQL 2005 Enterprise server.


  • Nice Find.

    Jason...AKA CirqueDeSQLeil
    I have given a name to my pain...MCM SQL Server, MVP
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

  • Didn't work for me either. Windows 7, SSMS 2008R2

    If I already have SSMS up and doubleclick on the file it opens, but when going from "scratch" it only opens SSMS.

  • BTW, my SSMS was run in Windows Server 2008 R2.

  • Just for reference:

    The reason why unassociating and reassociating the extension with Windows and SSMS didn't work is because this simply tells Windows what program to launch when a file with that extension is opened. In this case, because SSMS actually did open the association was working fine. It's what SSMS does with the file once it opens is the problem, which is purely an SSMS thing.

    Unfortunately, looking at the replies, what is causing SSMS to behave improperly is inconsistent and so are the fixes. 🙁

  • Wow. Fantastic find. I've complained about this forever.

    What's amazing is that it happens on so many systems.

    Thanks for the fix!

  • Thanks. This was actually my first Publication. Glad it helped. Hopefully I can figure out the elusive SSMS 2008 R2 that that has the same issue. A developer I work with just found that he had that issue today. This solution didn't work.

  • Very welcome. This was my first Publication. Hope to have more !

  • Solution does not work for me either, Win 7 x64. Since Windows 2008 Server R2 is also x64, maybe the issue lies there.

  • I am sorry that when i read this Article and just do it , it do failure ,my server is Windows2003 EE & SqlServer2005 EE sp2

  • Here is my problem..

    Whenever I try to open .sql file it keeps opening a new SSMS window. But originally, the .sql file will open as a separate tab if already a SSMS window is kept open, else it will open a new window.

    Is there a way to restore such configuration - when i already have a SSMS window open - and when i try to open .sql file from windows explore - this file should open as a new tab in the same existing SSMS window and should not open a new SSMS window.

    Any help would help a lot..

  • Very helful,


Viewing 12 posts - 16 through 26 (of 26 total)

You must be logged in to reply to this topic. Login to reply