Auto completion insertion keys behaviour

sfackrellsfackrell Posts: 3
edited July 20, 2010 5:14AM in SQL Prompt Previous Versions
Would be much better if when you chose space bar as an insertion key and there was only one suggestion, e.g. after you type "sel" it completed immediately rather than displaying the only suggestion and making you press the space bar again.

This is annoying and also different to how VS2008 intellisense works. Compare behaviour with typing "priv" in VS and pressing Ctrl+Space

1. SQL Prompt => S>E>L>Ctrl+Space>Space * => outputs SELECT
2. VS => P>R>I>Ctrl+Space => outputs private (C#)

* this step is unnecessary when there is only one suggestion.

Maybe you can change this behaviour in the options but I can't see how.

Comments

  • Anu DAnu D Posts: 876 Silver 3
    Many thanks for your post.

    Can you kindly check whether your option 'SQL Prompt 4 --> Options --> Behavior --> Automatically trigger suggestions' is selected or not?

    This will reduce your steps to:

    1. SQL Prompt => S>E>L> => outputs SELECT
    2. VS => P>R>I>Ctrl+Space => outputs private (C#)

    Kindly let me know if this setting is selected and still you have to press Ctrl + Space.
    Anuradha Deshpande
    Product Support
    Redgate Software Ltd.
    E-mail: support@red-gate.com
  • Thanks for your reply. Yes, this setting is checked. It's not that I don't want to press Ctrl-Space. I want to press Ctrl-Space but when I do and there is one and only one suggestion it should complete to this suggestion straight away, rather than leave a popup on screen.

    Regardless of how you type, if you have the letters SEL in the window and position the cursor to the right of L and press Ctrl-Space, it should change to SELECT immediately, not display a list with SELECT as the only valid suggestion.

    Compare this with well established behaviour in Visual Studio where only one valid suggestion means no need to press anything more than Ctrl-Space. E.g. open a new C# console application and type whi in the Main proc. Press Ctrl+Space. No drop-down, just autocompletion because while is the only valid choice based on the namespaces available.

    There also appears to a problem with these options and join syntax

    Reserved keywords: UPPERCASE
    Built-in functions: lowercase
    Built-in data-types: lowercase

    Then type left outer join => left OUTER JOIN or worse, type LEFT OUTER JOIN => left OUTER JOIN

    And can you stop the indentation after pressing return because it's often wrong? E.g. type

    SELECT *
    FROM sys.objects
    WHERE name = 'me'
    AND create_date = '20100630'

    and then press enter a few times. Cursor is still indented? Should go back to far left after one line feed.

    It's a great tool in principle but as when I tested the beta a few years back there are still too many little annoyances (for me anyway)[/img]
  • Anu DAnu D Posts: 876 Silver 3
    Many thanks for your e-mail.

    We appreciate your feedback and hence logged this as a feature request in our internal tracking system whose tracking id is SP-3283.

    It will be reviewed by product manager and than marked for the next release.

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