What are the challenges you face when working across database platforms? Take the survey

Erroneous quote added on indent

AndyIrvingAndyIrving Posts: 18
edited April 11, 2011 4:29AM in SQL Prompt Previous Versions
This may have been present in V4, can't be sure.

Steps to reproduce:
	SELECT 'blah' AS blah
) AS b
WHERE blah = 'blah'

select the whole line of the where clause and increase the indent of it, either by the toolbar icon or the menu item. then place the mouse cursor at the end of the line (where the 'blah' is - make sure you click at the very last character)

Extra quote is added:
WHERE blah = 'blah''


SQL Prompt

Microsoft SQL Server Management Studio 10.0.4000.0
Microsoft Analysis Services Client Tools 10.0.4000.0
Microsoft Data Access Components (MDAC) 3.85.1132
Microsoft MSXML 2.6 3.0 4.0 5.0 6.0
Microsoft Internet Explorer 7.0.5730.11
Microsoft .NET Framework 2.0.50727.3615
Operating System 5.1.2600


  • Options
    MikeyCMikeyC Posts: 249 Bronze 3
    I have found at least two ways to replicate this:

    1) click in the left margin to select the entire WHERE line and hit TAB. The line is indented, the text is unselected, the cursor position is put at the end of the line, and a ' is added.
    2) Select the WHERE line starting from the end and hit TAB, then click at the end of the line fairly quickly after it is indented. and the extra ' is added.

    At least a portion of this is related to a bug I reported in v4: SP-2881
  • Options
    Anu DAnu D Posts: 876 Silver 3
    Many thanks for your post Andy and apologies for inconvenience caused.

    As specified by Micheal it is already logged in our internal tracking System (SP-2881) and I have added your comments to it.

    I will update this forum thread as soon as it is fixed.
    Anuradha Deshpande
    Product Support
    Redgate Software Ltd.
    E-mail: support@red-gate.com
Sign In or Register to comment.