663 results found
-
Menu option: 'Normalize Line Endings'
Sometimes line-endings get messed up by source-control (looking at you Git) and "intellisense" will give you lots of green squigglies that you'd rather not commit to the branch.
A good menu option for SQL Prompt would be 'Normalize Line Endings' with a sub-menu selection of 'Windows' or 'Unix'. Then fire off a regex expression powered search and replace on the file. It's fairly easy to do manually with a Ctrl+Shift+F in Visual Studio, but in SSMS, it's more complicated to do so manually, I think.
Git does this to me once in a while, and I have to open the…
9 votes -
Paste copied table rows as seperate entities for snippets
I would like the ability to copy a set of items then treat them as separate items for formatting purposes. For example, say I grabbed these values from a results table.
'A'
'B'
'C'I would want to be able to paste them with the formatting I'd use for an insert, so they would look like this:
('A'),
('B'),
('C'),As it works right now though, copying and using the $PASTE$ placeholder will generate this.
'($PASTE$)',
'(A
B
C)',1 vote -
Ignore Begin statements with CTE immediately after
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 -
Purge tabs
At the moment to purge old tabs you need to open the tab history window and scroll to a certain point and right click and choose "Remove tabs older than this"
This can be a bit tricky so instead could we have a button (perhaps in options?) that will prompt you for a date and purge items last closed before that date.
8 votesThanks for the suggestion!
We’re actively reviewing this suggestion alongside some others for Tab History. We’ll update again here when we progress.
-
Mark same columns in JOIN conditions
It helps avoiding join on the same column (especially at inner join).
Example:
UPDATE A SET Column1 = B.Column2 FROM TableA AS A INNER JOIN Table B ON A.Column3 = A.Column3.
It happens usually by accident. The statement should be:
UPDATE A SET Column1 = B.Column2 FROM TableA AS A INNER JOIN Table B ON A.Column3 = B.Column3.14 votes -
Pin tab
So, Starred Tabs have been added, which is 1/2 of the capability I asked for a while back with "pinned tabs". We can remove tabs from Tab History either:
1 tab at a time.....100s of times per day for me
Older than x date - which does NOT work for me, because tabs that I want to keep around aren't always used every daySo, now that we can "Star" tabs, how about letting us clean up Tab History a little more cleanly. Such as:
1 tab at a time
Older than x, except Starred Tabs
Older than xThis…
2 votes -
Shortcut to move commas from start to end and vice versa.
I would like to only affect the placement of commas in a column list, without applying other formatting options. This would work similar to Ctrl-B, Ctrl-B to remove brackets or Ctrl-B, C to insert semicolons, in that no other formatting would take place.
There are times I have a rather well-formatted script but it has been written with commas at the start of the line and I prefer them at the end. A new shortcut would toggle placing commas at the start or end of the line without affecting other formatting within the script.
5 votes -
Allow tab history to stay open
I want to be able to keep my tab history open. I am rebuilding a lost development database and using search a LOT, but after I search, find a tab I want to look at more deeply or execute, the window disappears and my search predicate and place in the list of matching tabs is lost, so I have to enter search predicate and scroll back down each time. This is a VERY useful tool, but it would be so much more useful if I could just keep it open.
16 votes -
Show last known value of T-SQL variables in pop-up definition
If I declare variables and assign them values (either in declaration or subsequent SET/SELECT statement, it would be very helpful if SQL Prompt, along with displaying the declaration (e.g. @MyVar int (Scalar variable) in the pop-up, would display the last know value. So, if my declaration was:
DECLARE @MyVar INT = 123
the popup would show something like @MyVar int = 123 (Scalar variable).
I realize some might be rather long (string) or not displayable at all (e.g. table variables, cursors, etc.) but what appropriate showing the value that was set and last known could be very helpful in line…2 votes -
Ability to run Code Analysis against whole DB
With the deprecation of SQL Code Guard and it's replacement by Code Analysis there is one feature that we heavily used that is now no longer there, and that is the ability to run SQL Code Guard against the whole DB not just the query on the screen.
This allowed us to investigate new DBs that we'd inherited to see what sort of cleanup we might be looking at as well as giving us the ability to see if anything had snuck in to our existing DBs without going file by file.
I know there are other tools (like SQL…
16 votes -
Vertically align option for concatenated strings
When concatenating strings, it'd be nice to be able to align the "+" sign. The following is what I get now:
SELECT CASE
WHEN Col = 1
THEN 'Col 1'
ELSE ''
END + CASE
WHEN Col = 2
THEN 'Col 2'
ELSE ''
END + CASE
WHEN Col = 3
THEN 'Col 3'
ELSE ''
END + CASE
WHEN Col = 4
THEN 'Col 4'
ELSE ''
END AS ConcatStr
FROM #Test;But what I'd like to get is:
SELECT CASE
WHEN Col = 1
THEN 'Col 1'
ELSE ''
END
+ CASE
WHEN Col = 2
THEN 'Col…2 votes -
Additional Formatting Options
These are the typical formatting styles I use that I would like to see definable in SQL Prompt. Currently, I use a style that gets me close then manually format the remainder to the code:
Regarding the desired format of
1) SELECT, FROM, JOIN, WHERE, GROUP BY, HAVING, ORDER BY all lined up
2) TAB after SELECT, followed by first 'column'
3) Subsequent columns on separate lines and lined up with the first one.
4) TAB after any CASE followed by first WHEN
5) Subsequent WHENs lined up with first one
6) TAB before THEN (i.e. indented one tab from…4 votes -
too much prompting for upgrades
I'm constantly opening new SSMS windows, closing new ones, opening new visual studio windows, etc, and every time I open a new window, I have to acknowledge the upgrade prompt because it covers important parts of the window (like the status bar). Even if I select "next month" or "skip this version" I have to do the same for every new window I open since new sessions don't check for this option on existing sessions. SQL prompt is constantly getting updates (almost weekly, it seems), so i just start a new round of "skip this version" the following week.
Can…
3 votes -
SQL Prompt Code Visualization (Like Flow Chart)
SQL Prompt should be able to Visualize the Code and represent the code like Flow Chart.
This Feature will be very useful while working with heavy Stored Procedures.The Sample Code Visualization image is shared below:
https://drive.google.com/file/d/1dE0H7UP1MOuOZ4A3e4urUkDlR0FD4474/view?usp=sharing
21 votes -
Add option to wrap lines when concatenating strings
Sometimes I set a variable equal to many strings concatenated together using the "+" syntax. When I format with Regdate, there is no option to wrap lines in this case. Everything ends up on the same line as the SET, so the lines often get very wide and go off screen.
It would be great if there was an option to wrap text if things got too wide horizontally.
One solution would be a setting to format concatenated strings like this:
SET @Variable = N'String1'
+ N'String2'
+ N'String3'4 votesHi Amanda,
Would the ‘wrap lines longer than X characters’ option in the formatting styles help with this?
Tim
-
Add context menu shortcuts to SQL Prompt context menu entries
I want to be able to quickly switch between active styles.
I'm informed that the solution to this was to add the Active Styles section of the context menu, to allow quick access to the active styles.
That's fine as far as it goes, but that entry is very far down the menu and is only quickly accessible by mouse.I would like to suggest having the "Active Styles" entry changed to "&Active Styles" so that the A becomes a shortcut in the context menu; and to have each of the styles listed as &1, &2, &3 etc. in the…
1 vote -
Is there a way to run your code analysis rules against an existing database?
To help our developers we - as dba's - perform validation against their procedures and database code. The library of rules that is incorporated in SQLPrompt could be a good rule of thumb for the basic stuff of reviewing, so that we can focus on other stuff when validating.
Is it possible to run the rules "engine" of SQLPrompt against an existing database without having to open the code manually?3 votes -
Run Script at Cursor
Run Script at Cursor just Oracle SQL Developer with F5 or Alt+X. Please implement this very helpful functionality.
1 vote -
COLUMNPROPERTY
COLUMNPROPERTY (https://docs.microsoft.com/en-us/sql/t-sql/functions/columnproperty-transact-sql) is missing two suggested property values that were introduced along with System-Versioned tables in SQL Server 2016.
Please find the missing values below:
GeneratedAlwaysType
IsHidden1 vote -
Allow Copy/Paste contents of 'List of Code Analysis Issues' window.
Sometimes I would like to just copy/paste the issues discovered and include in an email. Currently, I cannot copy the Issues list. It takes too much time/effort to export to a file and then attach that file to an email. Copy/paste would be so much easier.
2 votes
- Don't see your idea?