Skip to content

SQL Prompt

Welcome to the SQL Prompt feature suggestion list. Find out more information about SQL Prompt at http://www.red-gate.com/products/sql-development/sql-prompt/.

If you have any questions, need help or have found a bug in SQL Prompt, please visit the forums or our support portal.

SQL Prompt

Categories

JUMP TO ANOTHER FORUM

  • Hot ideas
  • Top ideas
  • New ideas
  • My feedback

173 results found

  1. Indent the clauses that may follow an alter table statement. They currently are on the same line or split but not indented.

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  2. Whitespace: I picked up an indenting/alignment pattern from a Stack Overflow thread that solves an abundance of arguments: Please provide the option for using Tabs to indent the line, and then use spaces for alignments following the first character.

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  3. SQL prompt currently removes the empty line at the bottom of a script, which then break rule SC002.

    Can format include a setting to add a blank line at the bottom of a script, and also autofix sc002 issues.

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  4. Hi
    it is better to SQL prompt use only aliases define with user.

    need option in Aliases : Only For Custom Aliases

    Sorry For My Bad English

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  5. SQL Prompt's "Insert semicolon" function behaves weirdly when a CTE is a the start of a control loop. For example, if I have this code:

    IF (1=1) BEGIN
    WITH numbers AS (
    SELECT 1 AS num
    UNION SELECT 2
    UNION SELECT 3
    UNION SELECT 4
    )
    SELECT * FROM numbers
    END;

    SQL Prompt will format it as
    IF (1=1) BEGIN;
    WITH numbers AS (
    SELECT 1 AS num
    UNION SELECT 2
    UNION SELECT 3
    UNION SELECT 4
    )
    SELECT * FROM numbers;
    END;

    While the code runs, I think the semicolon after "BEGIN" makes very little sense. First, the beginning…

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  6. My Teams would prefer this option:

    xxxxxxxxxxxxxx (
    xxxxxxx,
    xxxxxxx )

    Opening parenthesis on the first line, and closing parenthesis on the last line.

    Second and following lines indented one stop. This display seems to strip out the leading spaces.

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  7. I have different wants for parentheses rules: Collapse short content or not, Having Parentheses on separat lines or leading the content, etc. It all depends on the context. But currently the setting is global.

    I would like to be able to define one rule for, say, Primary Key definitions, and another rule for, say, the columns of a table.
    I would want one thing for Control Flow sections, and another thing for Variables declarations.

    Today, I need to choose which one to be dominant (or stop using FORMAT SQL on the entire script, but just highlight the block where I…

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  8. It seems that the contents and closing parenthesis of EXISTS and APPLY clauses is not being indented as I would expect. So either i'm weird....or Format SQL is doing it wrong?

    I'm using (
    .....this parentheses style
    )

    What it's doing:

    SELECT *
    FROM tblA a
    WHERE 1 = 1
    .....AND EXISTS (
    .....SELECT *
    .....FROM tblB b
    .....WHERE b.Col1 = a.Col1
    ..........AND b.Col2 = a.Col2
    ..........AND b.Col3 = a.Col3
    )

    What I expect:

    SELECT *
    FROM tblA a
    WHERE 1 = 1
    .....AND EXISTS (
    ..........SELECT *
    ..........FROM tblB b
    ..........WHERE b.Col1 = a.Col1
    ...............AND b.Col2 = a.Col2
    ...............AND…

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  9. It's currently possible to align operations in WHERE which is great, but BETWEEN is not aligned.
    Example - currently:
    WHEREModifiedDate BETWEEN DATEADD(MONTH, -6, GETDATE()) AND GETDATE()
    AND City
    __________= 'Bothell'
    OR LEFT(PostalCode, 2)
    = 'CB'
    OR PostalCode
    _______= @prefix + @suffix

    Expected:
    Example - currently:
    WHEREModifiedDate_BETWEEN DATEADD(MONTH, -6, GETDATE()) AND GETDATE()
    AND City
    ________= 'Bothell'
    OR LEFT(PostalCode, 2)
    = 'CB'
    OR PostalCode
    _______= @prefix + @suffix

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  10. What I sometimes run into, is that a table gets an alias (by SQL prompt), that matches an acronym for a snippet. Then, whenever I'm writing out my query, while calling the table by alias, snippet manager replaces the alias with the full snippet. Which can be annoying as Ctrl-Z doesn't work.

    My suggestion would be to check the snippet manager before assigning aliases and not have them overlap.
    Thanks.

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  11. My default preference is to maintain the ON keyword without a new line. I would like to be able to CONDITIONALLY place the ON keyword on a new line if, and only if the ON keyword together with the associated ON condition exceed a configurable wrap threshold.

    Example:
    -- Yield this >>>>
    SELECT *
    FROM Person.Address
    INNER JOIN Person.StateProvince
    ON StateProvince.StateProvinceID=Address.StateProvinceID
    -- >>>> instead of

    SELECT *
    FROM Person.Address
    INNER JOIN Person.StateProvince ON StateProvince.StateProvinceID=Address.StateProvinceID
    -- Assuming the JOIN clause exceeds the wrap length
    -- <<<

    This is particularly useful if the "Place JOIN table on new line" is NOT selected…

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  12. It would be cool if SQL Prompt was able to remove trailing whitespaces/tabs not only for T-SQL, but also for comments.

    It's not something crucial, but rather nice-to-have

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  13. I think SSMSBoost has this feature: being able to add configurable guide lines to limit the query writing space to a specified number of characters/columns. This is very handy as I always want to keep my code narrow, within the 80-char limit. Currently, I have to install SSMSBoost for it... Could this please be added to SQL Prompt? This is probably a quick feature to implement and would be tremendously useful. Thanks.

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    2 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  14. If format SQL makes chnages - it destroy saved marks
    This occurs even when line bookmarked line hasnt (visibly) changed
    Very frushtrating

    3 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  15. Global formatting options like "Insert Semicolons", "Add brackets to all identifiers" etc should be part of a formatting style, this way changing a formatting style can also quickly switch between these options.
    Currently even after changing a formatting style these options on the screenshot below had to be manually changed one by one, it's inefficient to say the least.

    2 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  16. 2 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  17. When making a CREATE TABLE statement, I would like to have the comma at the beginning of the line.
    I've set the lists.placeCommasBeforeItems property to true, but it's not working for the DDL statement.

    So either fix the comma placement option for DDL statements or add an option for it.

    2 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  18. Would it be possible to include the attached menu options in the Style format configuration? It would be very helpful to have it when Formatting SQL instaead of executing it after the Format.
    At least, "Apply Casing Options", "Qualify Object Names" and "Remove Square Brackets".

    2 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  19. We have some comments placed in the code preceeded by one or more TABs. When formatting SQL all these TABs are replaced by one WHITESPACE.
    Is it possible to maiantain these TABs?

    See attached examples.

    2 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  20. We would like an option to get rid of the semicolons. You can only configure the whitespace. When we apply "Format SQL" many semicolons are inserted in our code and we don't wnat them.
    Is it possible to add an option when formatting Style for eliminating semicolons?

    2 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    0 comments  ·  Format SQL  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  • Don't see your idea?