SQL Prompt 5.3.4.1 Crashing SSMS on CTRL-K, CTRL-Y

Provides intelligent code completion for SQL Server editors.

Moderators: JonathanWatts, David Atkinson, Anu Deshpande, Paul Stephenson, Michelle Taylor, Mike Upton, justin.caldicott, Aaron Law

SQL Prompt 5.3.4.1 Crashing SSMS on CTRL-K, CTRL-Y

Postby blitzd » Wed Jul 25, 2012 4:57 pm

Starting this morning SQL Prompt has started crashing every time I use the CTRL-K, CTRL-Y key combinations. When I debug this is what I see:

System.NullReferenceException was unhandled
Message=Object reference not set to an instance of an object.
Source=RedGate.SqlPrompt.Engine
StackTrace:
at RedGate.SqlPrompt.Format.Layout.BackgroundDelegate.()
at RedGate.SqlPrompt.Format.Layout.BackgroundDelegate.()
at RedGate.SqlPrompt.Format.Refactoring.()
at RedGate.SqlPrompt.Format.Refactoring.()
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean ignoreSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()
InnerException:

SSMS then closes.

I'm using the RTM version of SSMS 2012, and this feature had worked with it up until today. When the issue started occurring I did check for an update to SQL Prompt, and there was one - which I installed, but the issue persists.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby blitzd » Thu Jul 26, 2012 2:55 pm

A complete uninstall/reinstall seems to have solved this problem.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby blitzd » Thu Jul 26, 2012 4:21 pm

Spoke to soon - just crashed again on Format SQL and lost everything I was working on.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby blitzd » Thu Jul 26, 2012 4:32 pm

Also in addition to this I have noticed that the RedGate buttons on the menu bar are acting very strangely - every time I move them and re-open SSMS they're either back to their default place, or they show up twice. If I remove the buttons altogether by unchecking the RedGate option, the next time I open SSMS they're back.

If I make any other modifications to non-RedGate buttons, they persist just fine.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby blitzd » Thu Jul 26, 2012 4:46 pm

I also noticed that after uninstalling all RedGate tools there was still a RedGate toolbar showing up, it was empty with no buttons.

I'm doing a repair of the shared features install for SQL 2012 to see if this resolves the issue.

If anyone from RedGate has some insight into this, it would be great to hear from you.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby blitzd » Thu Jul 26, 2012 5:15 pm

After a full uninstall of all RedGate products, a repair of SQL Management Studio 2012, and a re-install of the latest versions - I am still facing the same issues.

The RedGate and SQL Search toolbars comes back every time I re-start SSMS, despite being unchecked in customize toolbar options, or even deleted. They don't remember the position they were placed in, and often times the buttons that show up on either one appear to be random. Sometimes the RedGate toolbare has SQL Search on it, sometimes it doesn't. Sometimes the SQL Search toolbare has SQL Source Control and SQL Test on it, sometimes it doesn't. The most annoying aspect of this particular issue though, is that I do NOT want the toolbar in it's default place - I use that space for the SQL Editor toolbar.

What is more than an annoyance though, is the crashing - it's causing me to lose productivity. I've been using SQL Prompt for so long now that it's not even a conscious thought to reformat anymore. I hit that key combination at the end of typing any statement reflexively - and now it's causing crashes and lost work.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby Chris Auckland » Fri Jul 27, 2012 4:42 pm

Thanks for your post. I'm not sure why it keeps crashing SSMS for you. Did it give you the chance to submit a bug report when it crashed? If it does, can you send it in with your email address?

Could you also take a look at the log file? This can be found in SQL Prompt 5 > Help > Show log

With regards to the problem with the toolbar, I think this is a known issue. I'll just confirm that and let you know if/when it's going to be fixed.
Chris
Chris Auckland
 
Posts: 757
Joined: Tue Oct 24, 2006 2:12 pm
Location: Red Gate Software Ltd.

Postby blitzd » Fri Jul 27, 2012 4:58 pm

There is no chance to submit a bug report. The Laying out SQL window pops up, the progress bar will move a bit, and then the background SSMS window goes pale (unresponsive) and the program closes. Sometimes I have the option of debugging, sometimes I do not - the stacktrace that I first provided was the immediate error that was shown when I did a debug session on ssms.exe.

The log file shows only INFO messages when this crash occurs.

I believe I have identified the exact problem that causes the crash, it's when I go to format a statement like the below one:

Code: Select all
DECLARE @Variable INT = ?


The script I'm editing will be run in an SSIS Execute SQL Task, and the ? is how the parameters are passed to it. It does show in the editor as 'Incorrect Syntax' - but I wouldn't think that trying to format it should crash SSMS entirely.
blitzd
 
Posts: 32
Joined: Fri Nov 26, 2010 7:30 pm

Postby Chris Auckland » Mon Aug 06, 2012 2:47 pm

Sorry for the delay, I've been on holiday.

I can confirm that if you supply ? as a value for a parameter, the 'Format SQL' causes SSMS to crash.

I've logged bug SP-4489 for our developers to take a look at.

Thanks for finding the cause of the problem for us.
Chris
Chris Auckland
 
Posts: 757
Joined: Tue Oct 24, 2006 2:12 pm
Location: Red Gate Software Ltd.


Return to SQL Prompt 5

Who is online

Users browsing this forum: No registered users and 1 guest