663 results found
-
Aggrigate column name as
When writing SQL codes I frequently use aggregate functions such as Sum, count, avg etc.
When writing for exapmle sum(SalesVolume) it would be nice to have an autocomplete option to Sum(SalesVolume) As SalesVolume or Sum(SalesVolume) as SumSalesVolume.2 votes -
"Remove Square Brackets" option
The "Remove Square Brackets" option does not work for "CREATE EXTERNAL TABLE" statement.
Please try this option with the example below and nothing happens.
CREATE EXTERNAL TABLE [ft].[Account]
(
[AccountId] [bigint] NOT NULL,
[AccountType] [nvarchar] (50) COLLATE NOT NULL,
[AccountCreatedDate] [datetime2] NOT NULL
)
WITH
(
DATASOURCE = FinancialDB,
SCHEMANAME = 'Account',
OBJECT_NAME = 'Account'
);2 votes -
Tab History Add MRS
sometimes I need same string between different tabs in Tab History. each time I need to copy/paste the desired string. Would be nice if it would remember the most recent used searches same way as any Search box
2 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 -
Add option to ignore is_ms_shipped flag in suggestion list
When typing a snippet eg I type zcod I get 3 suggestions - but the top one is a merge replication conflict table definition for MSmergeConflictZZZFULLZZZcodt and the 2 below it are my own snippets starting with zcod
I don't understand why this is the case, my own suggestions that START with zcod should take precedence over an isms_shipped table that ends in zcod surely.
I see you recently added (I am on 9.5.11) ordering based on frequency and I never click this table as it serves no purpose so I cannot understand the behaviour.2 votes -
Provide optional colors for Warnings & Highlighting > highlighting
Options, Warnings & Highlighting, Highlighting. The light gray does not work well on a black background. I'd like to be able to select another color for that feature.
2 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 -
Format lists on a clause basis
I would like to control the list behavior on a clause by clause basis so that I can separate the formatting on my DECLARE statements differently than lists within SELECT and INSERT statements. As it stands, these are conflicting changes. So, the only way to get each variable declared on a separate line is to also have every column in other statements on a separate line. I'd like to be able to do BOTH of these:
DECLARE @GUID UNIQUEIDENTIFIER = NEWID(),
@Char CHAR(1) = 'A',
@Int INT = 1,
@Datetime DATETIME = CURRENTTIMESTAMP,
@Decimal DECIMAL(18,10) = 1.0,
@Date DATE…2 votes -
Custom values for VALUES clause
I write a LOT of unit tests, usually at the rate of 15:1 to 20:1 to my executing code. I have these standardized and templated to make them easier and more consistent to build. e.g. @GUID UNIQUEIDENTIFIER = NEWID(),
@Char CHAR(1) = 'A',
@Int INT = 1,
@Datetime DATETIME = CURRENTTIMESTAMP,
@Decimal DECIMAL(18,10) = 1.0,
@Date DATE = CURRENTTIMESTAMP,
@Time TIME = CURRENT_TIMESTAMP,
@Bit BIT = 1,
@Money MONEY = 1.00,
@Binary VARBINARY(18) = 0x01,These go into my VALUES clause for INSERT statements, but I current have to do all of this manually, which takes a LOT…
2 votes -
Load tabs into prior windows on SSMS startup
Currently I have query tabs in two separate windows within SSMS to view data and queries side by side. After closing and re-opening, it would be great if these segregated tabs went back into their appropriate windows. Along with that, it would be great if it would only load back in the tabs for the server we are connected too. Not also the tabs that I had open in a different instance of SSMS to a different server; which I had displayed on a different monitor for more side by side viewing.
2 votes -
2 votes
-
When excluding schema / database from suggestions, if provide excluded schema, suggestions should still appear, but limited to that schema
So i specifically excluded our "temp" schema from my suggestions and it works brilliantly, however, when specifically want that schema, after completing the schema name it should show me the suggestion within that schema? -
Currently my options are to remove the "don't show suggestions" for the temp schema and then add it again after this session.2 votes -
Snippet tags to insert other snippets
I like to get clever with snippets, and it would be great to be able to create dynamic snippets for different circumstances by being able to nest one snippet within the creation script of another. That way I can parse individual functionality in different snippets, but build them together to create more complex dynamic snippets without having to maintain the same basic code in multiple individual scripts.
I could see this working simply like:
snippet1:
DoThing;snippet2:
$snippet1$
DoMoreThing;2 votes -
Refreshing suggestions (Ctrl+Shift+D) should apply to all databases, not just the current one
Currently, when refreshing suggestions with Ctrl+Shift+D, only the new changes in the current database are seen. To load the changes in another database (that I'm referring with a 3-part name in a query), I need to change the current database to that one, press Ctrl+Shift+D and then change the current database back to the original one. If it's the first time I'm accessing the other database (since starting SSMS), the changes are loaded when typing the 3-part name. However, if I had previously accessed the other database, refreshing does not work as I expect: it should drop the entire cache…
2 votes -
Indent AND/OR in WHERE/GROUP BY/etc. differently than ON clause
Support request #137199: Provide an option to indent AND/OR entries in a WHERE clause to line up indented, but leave AND/OR entries directly underneath ON clauses:
SELECT
t1.col5
, t2.col6
FROM
table1 t1
INNER JOIN table2 t2
ON t1.col1 = t2.col1
AND t1.col2 = t2.col2 -- AND is directly below ON clause
WHERE
t1.col3 = 'Test'
AND t2.col4 = 5 -- AND is indented underneath WHERE2 votes -
format expressions like operator
Would it be possible to treat the 'LIKE' operator the same as '=' in the Expressions\Operators settings so they are all aligned?
select AddressID
from Person.Address
where ModifiedDate
between dateadd(month, -6, getdate())
and getdate()
and City = 'Bothell'
or left(PostalCode, 2) like 'CB%'
or PostalCode = @prefix + @suffix2 votes -
Make equals signs line up with tabs
When I type code I like to line up all the equals (=) signs using tabs so that all the code to the right of the equals sign lines up nicely on my screen. I find this really useful for improving readability when using column aliases, in joins, and in update statements.
I can't find an option in SQL Prompt to do this and it annoys me when I format my SQL and all the equals signs become ragged.2 votes -
Autofix for existing functionality
There are cases where the code analysis detects errors and where the tool already have functionality to correct the issue. For instance with unqualified column names
2 votes -
Allow me to specify relationships
I'd like to be able to give hints about how to join two tables. For example, column A in table 1 is the key for column B in table 2. It's not always possible to make that a real reference column so it would be nice if SQL Prompt knew that it should present it as an option when doing a JOIN clause.
2 votes -
Replace synonym with target object
I would really like the option to select the occurrence of a synonym in DML statement and have SQL Prompt replace it with the synonym's target object.
2 votes
- Don't see your idea?