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

275 results found

  1. When inserting code to execute a stored procedure, SQL Prompt currently automatically generates input variables of the correct data type, e.g.:

    EXECUTE ETL.spLoad_DimPerson
    @LatestLoadDate = '2016-06-21 18:51:43', -- datetime2
    @TargetRowsInserted = 0, -- int
    @TargetRowsUpdated = 0, -- int
    @TargetRowsDeleted = 0 -- int

    However, the syntax does not seem to recognize OUTPUT parameters. When I ask SSMS to generate a query for me by right-clicking and choosing 'Execute stored procedure...', it gives me the following:

    DECLARE @return_value int,
    @TargetRowsInserted int,
    @TargetRowsUpdated int,
    @TargetRowsDeleted int

    EXEC @returnvalue = [ETL].[spLoadDimPerson]
    @LatestLoadDate = '2005-06-21 18:41:59',
    @TargetRowsInserted = @TargetRowsInserted OUTPUT,
    @TargetRowsUpdated…

    15 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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Thomas Walsh responded

    Thank you for your suggestion.

    We’ve reviewed this as part of our UserVoice triage.

    Currently this feature is available in SQL Prompt.
    The OUTPUT and EXECUTE statements are auto generated.

    We don’t support the SELECT statement as part of this feature.

    Please feel free to raise a new feature request if this is something you would like.

    Kind Regards,
    Prompt Team

  2. The new Execution Warnings functionality to warn of UPDATE or DELETE statements without a WHERE clause is great; however, the warning triggers even when the code is in the definition of a Stored Procedure.

    It would be good then to have advanced functionality to allow for us to be able to select whether to warn on SP definition text, or to turn on the warnings when running against temporary tables.

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Andrei Rusitoru responded

    This feature was released in version 7.3 of SQL Prompt.

    If there are any missing features please let us know by creating a new suggestion.

    Kind Regards,
    The Prompt Team

  3. This is a clarification to an earlier post. (https://redgate.uservoice.com/forums/94413-sql-prompt/suggestions/13543761-enhancement-to-warning-on-delete-and-update-state)

    This is a great idea, but I was surprised by the number of "false positives" I am getting (and yes, I can just mute the messages completely).

    In my case I am doing a lot of updates/deletes on permanent tables with joins to temporary tables or table variables and that limits the update/delete scope.

    Can you add to this feature so that messages will not be emitted if there is a join to a temporary table or table variable?

    For example...
    Update dbo.RealTable
    Set SomeData = tt.SomeData
    From dbo.RealTable…

    6 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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Andrei Rusitoru responded

    This feature was released in version 7.3 of SQL Prompt.

    If there are any missing features please let us know by creating a new suggestion.

    Kind Regards,
    The Prompt Team

  4. This is a great idea, but I was surprised by the number of "false positives" I am getting (and yes, I can just mute the messages completely).

    In my case I am doing a lot of updates/deletes with joins to temporary tables or table variables and that limits the update/delete scope.

    Can you add to this feature so that messages will not be emitted if there is a join to a temporary table or table variable?

    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

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

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Aaron Law responded

    Thanks for your feedback on this feature! We’ve just released a new build of SQL Prompt (7.2.1) which won’t show these warnings when modifying temp tables with aliases.

  5. ALTER DATABASE <DB Name>
    MODIFY FILE (NAME = '', NEWNAME = '')

    1 vote

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Aaron Law responded

    Hi Lee,

    Thanks for letting us know about this. NEWNAME is now suggested in SQL Prompt 7.2 which you can download from our website or through Check for Updates in the SQL Prompt menu.

  6. I have never clicked on a suggestion that results in opening the Microsoft Help window on purpose.

    As an example, if I have a long "IsNull" that takes up multiple lines, a tip box will pop up blocking portions of the query, and no matter where I click, this will pop up and block different portions. Often I will accidentally click the box as I need the cursor to be where the box is, and it will cause the dev environment to become unresponsive while the "Help" window loads.

    1 vote

    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  ·  Intellisense  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Aaron Law responded

    Hi Danny,

    It’s already possible to disable these tooltips in SQL Prompt. If you open up the SQL Prompt options, on the first page it’s under “Show tooltips for: Parameters”.

    Thanks,
    Aaron.

  7. Correctly qualify the Table Value Constructor.

    I frequently use a TVC to find the Max value among several values on a single row, as with the following:

    ;WITH MyCte AS (SELECT 1 AS a, 2 AS b, 3 AS c)
    SELECT
    MyCte.a,
    MyCte.b,
    MyCte.c,
    HighestNumber = (SELECT MAX(Value.Val) FROM (VALUES (MyCte.a), (MyCte.b), (MyCte.c)) AS Value(Val))
    FROM MyCte

    When I qualify object names within that script, it incorrectly tries to add the 'Value' as a qualifier within the constructor:

    ;WITH MyCte AS (SELECT 1 AS a, 2 AS b, 3 AS c)
    SELECT 
        MyCte.a,
        MyCte.b,
        MyCte.c,
        HighestNumber = (SELECT MAX(Value.Val) FROM
    1 vote

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Aaron Law responded

    Thanks for letting us know about this issue. It should now be fixed in the latest build of SQL Prompt (7.1.0.314)

  8. SQLPrompt will take scientific notation, and alias it as 1[e1], 1[e2] and so on.

    1e1
    1e2
    1e3
    1e4
    1e5
    1e6
    1e7
    1e8
    1e9

    1 vote

    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)
    completed  ·  Aaron Law responded

    Hi Erik,

    Thanks for letting us know about this issue. It should now be fixed in the latest build of SQL Prompt (7.1.0.314)

  9. Sometimes, formatting makes a query less readable, e.g.

    insert table (col1, col2, col3, ....)
    values (1,2,3,...),
    (11,12,13,...),
    ...

    Formatting will put the values on multiple lines if there are enough of them. It's easier to see the data when they are on one line. So how about:

    --#region [optional description] #SQLPromptIgnore
    --anything in here doesn't get formatted
    --#endregion [optional description]

    Not sure what would be best for '#SQLPromptIgnore'

    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

    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)
  10. When using the new feature 'Open in Excel' (the results from the grid), it'd be handy to have an option to replace NULL string values with empty strings ''. Sure you could do ISNULL on all the columns that are a string data type, but it'd be handy to just have the option to have the 'Open in Excel' feature do it.

    The only way I've found to quickly do it is to export the data as a csv and use a powershell script with something like:
    Export-CSV -NoTypeInformation -Encoding "Unicode" -Delimiter "," $AttachmentPath
    (Get-Content $AttachmentPath) -replace "`0", "" |…

    8 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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  11. I love to have the options so that the first line of a stored proc is just the name i.e. create proc spName and the @parms varchar(20) and following would be on additional lines
    So for example

    create proc spName
    @Parm1 int
    ,@Parm2 int

    thanks
    Shannon

    4 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)
    completed  ·  Andrei Rusitoru responded

    This feature was released in version 8 of SQL Prompt.

    If there are any missing features please let us know by creating a new suggestion.

    Kind Regards,
    The Prompt Team

  12. when doing the auto complete on inserts give us an option to just fill in the column names like:

    insert into table(col, col, col)

    and nothing else - this is how I want 99% of the inserts that I write

    1 vote

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  13. When testing stored procs it's sometimes (or often) required to get the inside of the sproc and test it as a plain script. It would be helpful if SQL Prompt had an option to click a sproc and enable the coder to script it as a script with the input variables declared as plain variables at the head of the script (with maybe default values filled in already). It's something similar to taking script code and making it into a sproc but... the other way round :) It would make life easier for many a dev... Thanks!

    27 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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Andrei Rusitoru responded

    This feature was released in version 7.3 of SQL Prompt.

    If there are any missing features please let us know by creating a new suggestion.

    Kind Regards,
    The Prompt Team

  14. I want to switch between TEAM and PERSONAL styles for Format SQL. It currently takes 8 mouse clicks to achieve this. Could you add a style lookup on the context menu or Red Gate tools menu and apply the style to the current document automatically as soon as it is selected.

    I want my team to be able to work in their personal SQL format, but always save in the TEAM format.

    9 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)
  15. I have a lot of snippets. It would be great to have a search feature to find the snippet I'm looking for to edit it or see that I have it.

    6 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

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  17. If I select some code I can press Ctrl to open a small menu where I can e.g. "Apply comma" or "Encapsulate as procedure" etc.

    It would be nice to have a function to
    - remove line breaks
    - and / or replace line breaks with comma plus space
    - and / or encapsulate as IN condition

    Usage:
    Copy some Id's from a result set that you want to use in a IN condition

    Example:
    45486
    31321
    31167
    30985
    30844
    30818
    33989

    should be "formated" to
    45486, 31321, 31167, 30985, 30844, 30818, 33989

    1 vote

    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  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    completed  ·  Aaron Law responded

    Hi Thomas,

    We’ve got “unformat” in the actions list which’ll remove all the line breaks in the current selection.

    Apologies if unformat wasn’t an obvious action for removing line breaks – we had 3 UserVoice requests asking for it that had all used the term so it seemed like a good name to use.

  18. I would love to see the $CLIPOARD$ placeholder, representing the current text contents of the system clipboard (if there is any text in it, obviously).

    1 vote

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  19. Add a "closed tabs" list to the tab history - that's usually what I use it for rather than open tabs, which I try to keep to a minimum. That said it makes it hard when there are a dozen tabs all called "SQLQuery1", "SQLQuery2" to know which are open and which are closed...

    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

    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
  20. When you have a nested inner join to an outer join, such as:

    SELECT a., b., c.*
    FROM
    A a
    LEFT JOIN B b
    INNER JOIN C c on b.bid = c.bid
    ON a.aid = b.aid

    It should allow an option to indent the nested join further to show that it is nested

    5 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)
  • Don't see your idea?