SQL Server

Microsoft SQL Server powers your entire data estate by supporting structured and unstructured data sources. It builds on previous versions of SQL Server, which have been industry leading for four years in a row and a leader in TPC-E. It scales to petabytes of data and allows customers to process big data through PolyBase using T-SQL over any data. SQL Server has also been the least vulnerable database during the last seven years. SQL Server brings data insights with business intelligence capabilities that provide analytics at a fraction of the cost on any device along with advanced analytics with support for R and Python.

More details about SQL Server are available in the SQL Server documentation.
If you have a technical issue, please open a post on the developer forums through Stack Overflow or MSDN.


  • Hot ideas
  • Top ideas
  • New ideas
  • My feedback
  1. SSDT Database Project incorrectly flags reference as a circular reference

    I have a data warehouse project with 4 SQL Server databases Extract/Cleanse/Transform/DataWarehouse. Rather than using three-level names for anything (esp. views), I'm using synonyms whenever I need to use an object in another database. Since table names repeat across the logical layers, I'm using schemas in each layer: ext/cln/trn/dwh. This approach makes it easier for me to promote from dev/test/prod.

    In the Transform layer, I use a number of tables (synonyms) from the Cleanse layer as source tables. However, there is one table I first need to update in the DataWarehouse layer to generate surrogate keys for the natural keys.…

    2 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  2. SSRS Excel Render Extention Document Properties

    Enable the ability to specify Excel document properties; Category, Comments, Tags, etc...

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  3. Parallel SELECT INTO from sys.messages causes intra-query deadlock

    Loading data into a new table from sys.messages using parallel SELECT INTO causes consistent self-deadlocks. Testing on a machine with default parallelism settings and 4 logical cores. This occurs in SQL Server 2014, 2016 and 2017. Here's a reproduction:

    BEGIN TRANSACTION;
    
    

    SELECT TOP 10000
    m.message_id, m.[text]
    INTO SomeNewTable
    FROM sys.messages m

    For some reason, removing the "BEGIN TRANSACTION" reduces the frequency of deadlocks caused by this query. I've attached a deadlock graph from the issue.

    It's possible that bulk loading from sources like sys.messages is simply not a supported scenario - but, if so, this should be documented (or potentially…

    11 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  3 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  4. SQL 2017: "SET FMTONLY ON" doesn't return any resultset on UDF w/ COMPATIBILITY_LEVEL=140

    Our application uses at various places the SchemaOnly attribute (see https://msdn.microsoft.com/en-us/library/system.data.commandbehavior(v=vs.110).aspx). Lately, we noticed some strange errors when the application runs against a DB on SQL Server 2017. I boiled the issue down to the attached repro script in T-SQL, that shows clearly that SQL Server doesn' return any metadata, if a table-valued function is called using SET FMTONLY ON with COMPATIBILITYLEVEL=140. But it works as expected using COMPATIBILITYLEVEL=130. As I didn't find any word on this breaking change in the docs, I consider this a bug.

    23 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  6 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  5. SQL Server data import and export wizard unusable in SSMS 17.7

    The SQL Server Import and Export wizard became unusable, when I'm trying to import the content of a table from a different SQL database into the current one.

    First the setting of the connection required a lot more work than before (for example in SSMS of SQL 2012).

    Then loading the list of the tables and views from which to import took about 2 minutes for about 1500 objects, while it took only 2 seconds in SQL 2012.

    Then the list was completely randomly sorted, so I couldn't find my table in the list of the objects.

    I had to…

    2 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  6. Ability to run specific SQL Agent job steps

    Occasionally a user may need to run only specific steps of an agent job, or need the job stop after a certain step.

    While SQL Server Agent currently provides the ability to "Start job at step", this is all the flexibility the user has at runtime. Anything beyond that requires the job to be edited.

    It would be useful for those with permission only to run (not edit) jobs to have greater flexibility at runtime. E.g. a screen which allows the user to choose which steps to run or skip for that particular execution.

    28 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  1 comment  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  7. Unable to open a Management/Maintenance Plan on SQL2017 from SSMS v17.8

    Unable to open a Management/Maintenance Plan on a SQL 2017 database. SQL 2016 works fine. Note that the two 2017 databases I've tried this on were in-situ upgraded from SQL 2016. Error:

    Error loading 'DBMP_Daily - sa' : The LoadFromSQLServer method has encountered OLE DB error code 0x80004005 ((null)). The SQL statement that was issued has failed.

    server=some2017instance,21433;package=Maintenance Plans\DBMP_Daily;username=sa;

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  8. SSMS is not able to delete multiple models via object browser details via script

    it just picks some of the models selected when scripting out the xmla command.
    GUI works as expected...

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  9. Cannot find the certificate 'MS_Cert_Proj_{#}', because it does not exist or you do not have permission. During SSIS Deploy

    I am unable to deploy any SSIS packages after a clean install and upgrade to SQL 2014 SP2 CU12. The SSISDB is newly created an error occurs in the internal stored procedure that creates the symmetric key. No other errors are reported or logged.

            SET @sqlString = 'CREATE SYMMETRIC KEY ' + @key_name +' WITH ALGORITHM = ' 
    
    + @encryption_algorithm + ' ENCRYPTION BY CERTIFICATE ' + @certificate_name

    IF NOT EXISTS (SELECT [name] FROM [sys].[symmetric_keys] WHERE [name] = @key_name)
    EXECUTE sp_executesql @sqlString

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  1 comment  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  10. SSRS Map Component position bug

    I've attached an example where I have a map component that uses a hardcoded query to output a geography (simple triangle). The component shows also Bing tiles underneath. When viewing the report in the browser (http://127.0.0.1/ReportServer) everything look good. But when exporting as PDF, the polygon shows correctly but the Bing tiles are positioned incorrectly somewhere in the Southern Ocean. As soon as I modify slightly the map container size or the zoom of the viewport, everything is fixed. It seems the bug is triggered only for a certain ratio between the polygon MBR size and map container…

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  1 comment  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  11. Add setting so LEN counts trailing whitespace

    Maybe there is a historic reason why LEN('a') and LEN('a ') return the same number.

    But that's stupid.

    The internet is awash with people like me who were stunned to discover this counter intuitive quirk (Google it).

    None of the solutions to this problem are particularly elegant or efficient:
    https://stackoverflow.com/questions/2025585/len-function-not-including-trailing-spaces-in-sql-server/2025587

    I'm assuming since this has been baked in for ages, we can't change default behavior.

    So how about:
    - Add a parameter to the LEN function to count white space
    - Add an SQL Option that more generally keeps SQL Server's hands off my white space - everywhere

    32 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  8 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  12. SSMS - Query Store link to share

    If i'm working on a problematic issue with another DBA (or a team of), it would be great to share the QueryStore window i'm currently looking at. Is there a way to generate a link with protocol that SSMS will pick up and send me to the same view?

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  13. SSMS 17.8 script execution error when importing bacpac

    Error SQL72014: .Net SqlClient Data Provider: Msg 156, Level 15, State 1, Line 1 Incorrect syntax near the keyword 'NULL'.
    Error SQL72045: Script execution error. The executed script:
    CREATE AGGREGATE [dbo].StrConcat NULL)

    RETURNS NVARCHAR (4000)
    
    EXTERNAL NAME [Metadata.SQLFunctions].[Metadata.SQLFunctions.StrConcat];

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  14. SSMS execution plan tab scroll state not maintained..

    SSMS execution plan tab scroll state not maintained when changing between tabs (Results, Messages)

    Am using SSMS 17.5

    I my execution plan window i have almost 10 plans displayed.
    Assume am checking the 5th plan and i switched to the "Results" tab and when coming back to "Execution Plan" tab, the plan is auto scrolled to the top area. So always i need to keep scrolling down to the right plan. This is a tedious job.
    Please keep the scroll state.

    Thank you

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  15. SSRS Mobile Report Publisher : opening any chart in focus mode shows data in not readable format

    When I open pie chart in focus mode and then long press on it to see values, values are shown in very small font that those are not readable.

    1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  16. 1 vote
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Bugs  ·  Flag idea as inappropriate…  ·  Admin →
  17. financial functions

    Why can't SQL include the same financial functions that Excel offers?

    This request is decades old... give us NPV, IRR, PMT, etc...

    Oracle has had them, why can't SQL?

    5 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  18. Use Zstandard compression instead of LZ77 across SQL Server

    I suggest changing the columnstore archival compression algorithm from LZ77 to Zstandard, which provides better compression ratio, while being much much faster at compression and decompression speeds. The reference implementation is licensed with BSD license. https://facebook.github.io/zstd/

    Performance of Zstandard tends to be order-of-magnitude better than LZ77.

    Any compression used by SQL Server can benefit from that: columnstore archival compression, backup compression, maybe even page compression. It is worth considering if TDS can also use Zstandard compression to decrease network transmit time of large data sets and generally increase performance (also of linked servers). This TDS compression could be configurable so…

    3 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  19. Explain why indexes were skipped

    Feature request: expose information about what indexes the optimizer considered while compiling an execution plan. Specifically, the index names and WHY the index was rejected for that particular query. This could potentially be included in per-operator execution plan properties (see attached mockup), an extended event target, or some other avenue.

    Reason: many developers and DBAs wonder why certain indexes on their tables aren't being chosen for specific queries. This gives them better tools to figure that out and make better use of the SQL Server product.

    I've blogged about this feature request in more detail here: http://joshthecoder.com/2018/06/21/feature-request-index-rejection-reasons.html

    This request was…

    176 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  2 comments  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  20. Support Parameter Embedding Optimisation for queries that assign to variables

    OPTION (RECOMPILE) is needed to get a filtered index to match when the predicate is using variables or parameters.

    Recently I had a need to perform conditional logic in a stored proc dependant on whether or not a predicate (matched by a filtered index) contains any rows.

    1st attempt

    IF EXISTS(SELECT ...)

    But no way of applying a query hint to the query in an IF that I can see so no way of adding OPTION (RECOMPILE).

    2nd attempt

    SELECT @RowsExist = CASE WHEN EXISTS(SELECT ...) THEN 1 ELSE 0 END OPTION (RECOMPILE)

    But this doesn't work either as the…

    3 votes
    Sign in
    (thinking…)
    Sign in with: Microsoft
    Signed in as (Sign out)

    We’ll send you updates on this idea

    under review  ·  0 comments  ·  Suggestions  ·  Flag idea as inappropriate…  ·  Admin →
  • Don't see your idea?

SQL Server

Categories

Feedback and Knowledge Base