Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 126936

SQL Server 2016 (major build version 13.00.xxxx). Please also tag sql-server.

1 vote

We are using MSSQL 2016 / SSMS 18.9.2 and trying to script out a system versioned table with...

Looks like a bug in SQL Server Management Objects (SMO). You can track the issue here.
David Browne - Microsoft's user avatar
3 votes
Accepted

alter compatibility level

What is best practice for changing the compatibility level - before or after the SP2 and cumulative updates are installed? SQL Server 2016 SP1 is out-of-support so you should upgrade to supported se …
David Browne - Microsoft's user avatar
1 vote
Accepted

SQL Server LicenseType is disbled

Any idea how can I change LicenseType of SQL Server? Since licenses are assigned to servers externally, you can switch which licenses are assigned to which servers any time you want, subject to t …
David Browne - Microsoft's user avatar
3 votes

SQL Server - Space Available

From looking at a Profiler trace of the SSMS dialog opening the queries are essentially: Size: SELECT sum(df.size) * 8 / 1024.0 Size_MB FROM sys.database_files df; and Space Available: with q as …
David Browne - Microsoft's user avatar
8 votes

Mandatory to use "Three Parts Name" in T-SQL statements of SP

Using three-part names in queries that reference objects in the current database is a terrible practice and you should create a rule against it. The most frequent problem with it is that it prevents …
David Browne - Microsoft's user avatar
2 votes

Can we use save transaction command only in nested transactions?

I am a newbie to SQL and I came across a situation where I have to use save transaction Savepoints are rarely used (or useful) and it's unusual that "a newbie" would "have to use save transaction …
David Browne - Microsoft's user avatar
3 votes
Accepted

Most efficient way to cancel or avoid select in union query?

What is more efficient, using one scalar variable as in the previous example or using IF sentences and create specific queries as in the example below? In SQL Server a query plan may not vary bas …
David Browne - Microsoft's user avatar
2 votes
Accepted

Does an INSTEAD OF trigger gets re-created every time you insert into a view?

The trigger is not being recreated. sql_text in sys.db_exec_requests is at the batch level, not the query level. See eg https://blogs.msdn.microsoft.com/dbrowne/2013/01/18/my-favorite-query-for-inv …
David Browne - Microsoft's user avatar
3 votes

SQL Server Backups suddenly change size

A database backup contains the allocated extents plus the parts of the log required to replay any activity that occurred during the backup, and restore the database to the point-in-time at which the b …
David Browne - Microsoft's user avatar
1 vote
Accepted

Can I migrate 2 tables (with one table foreign key referencing the other) to in-memory OLTP

Seems like I need to do this to both tables at the same time Correct. If you try to recreate the FK after migrating one table you will get: Msg 10778, Level 16, State 0, Line 20 Foreign key re …
David Browne - Microsoft's user avatar
3 votes

How to INSERT a row INTO a table that has an 'order' column without cursor

Another common design here it to make the ordering column a float. Then you can always insert new rows before, after, or between the existing rows.
David Browne - Microsoft's user avatar
3 votes

Automatically expiring records in a temporal table?

This is the essence of what it means to be a system_versioning temporal table. You cannot control the row start and row end values. If you want the rows to be deleted after 5 days, you'll have to ha …
David Browne - Microsoft's user avatar
1 vote
Accepted

can SQLSRV32.DLL broker a TLS 1.2 handshake?

SQLSRV32.DLL is the old SQL Server ODBC driver that's part of Windows. In October 2020, Windows finally dusted off the source code for the built-in ODBC and OleDb SQL Server drivers and updated them t …
David Browne - Microsoft's user avatar
5 votes

SQL Server 2016 expiration date

How can exactly know the expiration date? You've found it. It is expired, and out-of compliance. It will stop working soon. There should be no need to wipe and reinstall SQL Server. Y …
David Browne - Microsoft's user avatar
5 votes
Accepted

Begin transaction doesn't lock table

If you can run a SELECT query against a table that another session has X locks on in Read Committed isolation, you must be in a database with READ_COMMITTED_SNAPSHOT set. With READ_COMMITTED_SNAPSH …
David Browne - Microsoft's user avatar

1
2 3 4 5
10
15 30 50 per page