270 results found
-
Code Analysis config to flat file
Code Analysis released in 9.0 is awesome! But I turn off a lot of the rules for day-to-day work. I know not to release production code with "select *" in it... But not all the devs do... so I have to click these rules back on to get Code Analysis to help me when I'm doing review.
Could we have profiles for CA like in Format SQL? Better still, could we have the config of these profiles in flat files? I could version & share different profiles with devs - allowing them to check rules I'm going to check anyway…
7 votesHello,
We added this feature recently (in SQL Prompt 9.1.0.4138).
Now it is possible to save your settings file in a shared folder for the team to use or switch between different settings files. This is accessible via the Prompt menu : SQL Prompt > Manage Code Analysis Rules….
Let me know if you find it helpful.
Kind regards,
Alicja -
SQL Formatter error
When using OPENJSON with the WITH clause, the formatter does not recognize the WITH clause as valid SQL. This should format but throws an error:
DECLARE @JSONString NVARCHAR(MAX) SET @JSONString = N'{"Vendors":[{"VendorNumber":200,"VendorName":"Vendor1"},{"VendorNumber":201,"Vendo2"},{"VendorNumber":202,"VendorName":"Vendor3"}]}'
SELECT VendorNumber ,
VendorName
FROM OPENJSON(@JSONString, '$.Vendors')
WITH (VendorNumber INT '$.VendorNumber', VendorName VARCHAR(50) '$.VendorName')2 votesThis formatted error has been fixed in the latest version SQL Prompt 8:
https://forum.red-gate.com/discussion/80988/latest-stable-build-of-sql-prompt-is-8-0-0-1241-11th-may#latestThanks for your suggestion!
-
SQL Prompt > Format SQL Update for SQL Server 2016
Any query where "AT TIME ZONE" is used (new feature in SS '16), the Format SQL throws and error.
"SQL Prompt was unable to complete this operation. Problem areas have been highlighted"
The highlighting start from "AT TIME ZONE..."
Thank you
14 votesWe now support “AT TIME ZONE” in the latest release of SQL Prompt. You can download the latest release here:
https://forum.red-gate.com/discussion/80988/latest-stable-build-of-sql-prompt-is-8-0-0-1241-11th-may#latestThanks for your support!
-
Formatting of AT TIME ZONE
In SQL Server 2016 it is now possible to calculate between timezones. Currently it gives me an error, when I want to format it. The syntax is also not allowed at the moment.
1 voteAT TIME ZONE is now supported in SQL Prompt 7.4
You can download the latest version of SQL Prompt from http://www.red-gate.com/products/sql-development/sql-prompt/
-
create or alter
SQL server 2016 SP1 introduced the "CREATE OR ALTER" PROCEDURE/VIEW - syntax, which would be very nice to have support for.
1 voteThis 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 -
OPTION
Hi!
Would be good to control the formatting of the OPTION clause.
I personally prefer to have it on a new lineSELECT
*
FROM
Production.Product p
LEFT JOIN
Production.ProductSubcategory s
ON
p.ProductSubcategoryID = s.ProductSubcategoryID
WHERE
p.ProductSubcategoryID = 14 OPTION(QUERYTRACEON 8757);
GO--should look like
SELECT
*
FROM
Production.Product p
LEFT JOIN
Production.ProductSubcategory s
ON
p.ProductSubcategoryID = s.ProductSubcategoryID
WHERE
p.ProductSubcategoryID = 14
OPTION(QUERYTRACEON 8757);
GOThanks!
4 votesThis 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 -
Formatting of Valid Selected code when there is invalid code in the script
I used to be able to format selected code, as long as it was valid. Now when I select code that is valid in a larger script that has invalid code it does not format the selected code at all. If the invalid code immediately precedes it it will suggest that there is an error in the first character of my selection when there is none, else it will just act like it did something but do nothing. This used to work and is a frustration now. This has been the case with both 7.3 betas and I believe at…
1 vote -
format is now deleting extra lines after the query
Looks like version 7.3 of SQLPrompt removes all blank lines after the query that it formats. Please change this back or make it optional to delete blank lines at the bottom of the query.
1 voteWe’ve just shipped a new beta build (7.3.0.619) that will preserve the extra lines at the end of the query if “Preserve existing new lines between statements” is checked.
You can download the latest beta build from https://forums.red-gate.com/viewtopic.php?f=169&t=79994
-
DBCC SHOW_STATISTICS('...','...) WITH DENSITY_VECTOR
Hi!
It would be nice to have an IntelliSense for the DBCC SHOW_STATISTICS command.
When typing
DBCC SHOWSTATISTICS('HashAggregation','WASys00000001_2A8B4280')
it would be helpfull to get the option of "WITH DENSITY_VECTOR" for example.
1 voteThis 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 -
deleting snippets with d
It would be nice if pressing the "d" key did NOT delete a snippet in the Snippet Manager!
It took me two key strokes to figure out why the program didn't went to the first snippet beginning with a "d" - and now I have to spend time figure out what I have been deleting!!
Of course, being able to navigate the long list of snippets using only the keyboard would be nice too. But of less importance. Deleting stuff without warning is bad, though!
1 voteThis 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 -
Apply Tab Colors on any schema-updating tabs too
Currently Tab Colors applies only on the Query tabs. It's much better to
apply on schema-updating tabs too. Tabs such as Table/View designer or even Red-Gate SQL Source Control tab :)1 voteThanks for your suggestion Reza!
We have already implemented this in the latest version of SQL Prompt so if you upgrade then both the table and view designers should have their tabs colored in the same way as queries. If they’re not being colored after upgrading to SQL Prompt 7.2 then you may have hit a bug so please do let me know.
-
Don't alias objects with reserved words
CREATE TABLE dbo.GrumpyOld (col1 int)
SQL Prompt will alias the table as GO, which causes problems because it's a batch separator.
Thanks!
1 voteThis 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 -
decimal
Hi, It would be great, if you add precision and scale on numeric/decimal data types - column hint and table summary.
3 votesThis 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 -
Option to remove gutter menu
Please provide a way to turn off the gutter icon. I do not use it but what DOES happen is that I constantly activate it when I'm selecting and moving around in my sql. It's annoying - extremely.
1 voteHi Nick,
This should already be possible in the latest version of SQL Prompt (7.2.4), you can right click on the icon in the gutter and select “Disable actions list”. Alternatively there’s a check box in the SQL Prompt options on the behavior page for “Show actions list for selected test” and unchecking this should also disable the feature. If you have any problems with it still appearing after you’ve disabled it just let me know.
Thanks,
Aaron. -
Add support for Azure Active Directory authentication
Referring to this forumpost: https://forums.red-gate.com/viewtopic.php?f=169&t=79794
55 votesThis is now completed and was shipped in v10.4
Thank you for your input!
Chiara
-
Add OUTPUT parameters when executing a stored procedure
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 -- intHowever, 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 intEXEC @returnvalue = [ETL].[spLoadDimPerson]
@LatestLoadDate = '2005-06-21 18:41:59',
@TargetRowsInserted = @TargetRowsInserted OUTPUT,
@TargetRowsUpdated…15 votesThank 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 -
Configurable Execution Warnings
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 votesThis 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 -
Enhancement to "Warning on delete and update statements if no WHERE clause is specified" (clarified)
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 votesThis 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 -
Enhancement to "Warning on delete and update statements if no WHERE clause is specified"
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 votesThanks 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.
-
Change Filename add NEWNAME
ALTER DATABASE <DB Name>
MODIFY FILE (NAME = '', NEWNAME = '')1 voteHi 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.
- Don't see your idea?