Wednesday, October 28, 2009

SQL Server crash

I just started SQL Server, connected to my SQL Server Compact DB, and got a null reference error. My SQL Server 2008 is now showing me the connection dialog, but there are no options in it. Here's the error that I was shown:

See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.SqlServer.Management.UI.ConnectionDlg.LoginControl.UpdateInstanceLabel()
at Microsoft.SqlServer.Management.UI.ConnectionDlg.LoginControl.Sync(UIConnectionInfo ci)
at Microsoft.SqlServer.Management.UI.ConnectionDlg.ConnectionDialog.DoOneTimeInitialization()
at Microsoft.SqlServer.Management.UI.ConnectionDlg.ConnectionDialog.OnVisibleChanged(EventArgs e)
at Microsoft.SqlServer.Management.UI.VSIntegration.ShellConnectionDialog.OnVisibleChanged(EventArgs e)
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

How is this remotely possible ? It sure isn't acceptable. Here is the dialog box:




On top of this, my SQL Server 2005 ( my default instance ) just up and died a week or so ago. I've spent far too long on google, and I can't work out how to make it work, if I start the service, it just stops. I've googled the errors in the logs, but I've had no luck. I've basically given up on it at this point, if I need any of the data, I assume I can import it in to SS2008 from the files on my file system still...

3 comments:

  1. Christian -

    Can't guarantee this will help you any but based on the screenshot and knowing what I do about Vista (I am assuming you are running a version fo SQL Server on your Vista computer or at least the client tolls for SQL Server, namely SSMS) I'd have to say it looks like a default location/path used by SSMS (SQL Server Management Studio) is no longer accessable be it because it's invalid/gone and or for security reasons.

    Not sure if you know this or not but you can enable and or disable the UAC in Vista on the fly, without any kind of reboot, as a way to test problems to see if they are in any way connected to Vostas UAC feature. i have 2 reg files for this, one disables the UAC and the other re-enables it. My suggestion would be to turn of UAC and then try this again. if that doesn't work then try connecting to your SQL Server from another computer via SSMS or any other DB Conect capable item like one of the serveal free SQL Server management tools out there. Microsoft even has (at least they used to have) a web based connect tool.

    I also have a VB6 app I put together that is a very lightweieght (no install, just 1 executable) ado enabled connection tool that I used in teh past to verify SQL Server connectivity issues were not due to a problem in the SSMS software but something else like a bad password/username combo.

    Let me know if you are interested in either the reg file or the ado VB6 authored applet.

    Ed Carden
    ed.carden@westdale.com
    DBA / Analyst
    Dallas, TX

    ReplyDelete
  2. Hi Ed. Thanks for your comments. No, the SQL Server is not on Vista, it's on XP SP3. I only use Vista to try to reproduce bugs that are reported on Vista, or to do Vista testing. I will check out what you said re: UAC b/c as a rule, I keep it on so that my machine is vanilla for testing. This causes all sorts of problems ( UAC pops up every time I read my web mail, for instance ), but there seems to be no point in making Vista usable for me, and then not testing how it runs for my clients.

    ReplyDelete
  3. Peace!
    You can solve this problem by deleting SSMS files in C:\Users\\AppData\Roaming\Microsoft\SQL Server management Studio

    ReplyDelete