Log in | Register

Transact-SQL Archives - SQL Server Blogs, Events, Webcasts, Videos, SQL Server learning & education Transact-SQL Archives - SQL Server Blogs, Events, Webcasts, Videos, SQL Server learning & education

SQLServerGeeks Annual Summit 2016 IS HAPPENING IN BANGALORE. HAVE YOU REGISTERED?

SQL Server – ROW_NUMBER versus TOP N

Hello Friends,

This blog post is the result of question asked by some professionals working on databases. While writing T-SQL code they generally use TOP N in the code to get the top n number of rows in the result set. They knew the another way to achieve the same result by using ROW_NUMBER. Now the […]

Compare Query plan using SSMS

Recently Microsoft released SSMS 17.0. This release of SSMS supports SQL Server 2017 for both running on Windows and Linux. In this release Microsoft has added new features as well as improved some existing features. One of them is to Compare Query plan.

You can download latest SSMS 17.0 here

This is helpful where you have […]

SQL Server 2017 – SELECT INTO on FileGroup

Microsoft has announced SQL Server 2017 CTP version with lots of new features and improvements as compare to previous version i.e. SQL Server 2016. You can download the SQL Server 2017 in the fastest way as explained by Avanish in his recent post. In this blog post we will learn about the new feature […]

Database Scoped Configurations and Trace flag 4199

Those who are working on query performance whether you are a DBA or Developer I am sure you guys must have used trace flag 4199.  TF 4199 enables all query optimizer related fixes.Microsoft used to have separate TF for each hotfix applied to query optimizer prior to SQL Server 2005 Service Pack 3 (SP3) Cumulative […]

By |April 16th, 2017|Categories: Database Administration, Database Development, Performance, SQL Server, Transact-SQL|Tags: , , , |Comments Off on Database Scoped Configurations and Trace flag 4199

SQL Server 2016 – Two things developers should know

Hello Friends,

There are lots of new features and improvement launched by Microsoft in SQL Server 2016. There are two small but really interesting things for the T-SQL Developers, DBA Developers who are involve in writing T-SQL code.

Situation: Let’s think about a situation where we are creating a new object (for example –  Stored Procedure) […]

By |April 3rd, 2017|Categories: SQL Server, Transact-SQL|Tags: , |Comments Off on SQL Server 2016 – Two things developers should know

DBCC CloneDatabase

This blog was due from a long time.  With the release of SQL Server 2014 Service pack 2, a new DBCC command included that is DBCC CloneDatabase. My primary job role is to do query tuning and I was looking for this kind of functionality. Using this command, it is quite easy   to copy […]

By |March 15th, 2017|Categories: Database Administration, Performance, Transact-SQL|Tags: , , |Comments Off on DBCC CloneDatabase

New Function String_Split in SQL Server 2016

SQL Server 2016 has many features which makes developer life bit easy to do various task. Earlier to split a string developer use to write a user defined function using temp tables and complex logic. In almost every database I see a user defined function exists which does string split work. The project for […]

By |March 8th, 2017|Categories: Database Development, Programming, SQL Server, Transact-SQL|Tags: , |Comments Off on New Function String_Split in SQL Server 2016

Step by Step Guide to Install, configure and Run R script in SQL Server 2016

Microsoft acquired Revolution Analytics in 2015 and integrated R in SQL Server 2016.Today I will show you how to install, configure and run R script in SSMS. Like all other Microsoft software installation of R is pretty easy. You just need to run the set up and with few click on Next button will […]

By |February 28th, 2017|Categories: Database Administration, SQL Server, Transact-SQL|Tags: , , |Comments Off on Step by Step Guide to Install, configure and Run R script in SQL Server 2016

New Security Features In SQL SERVER 2016 – PART 1

Data Security in any application is vital. Different business or application  has their own security policy.  SQL Server 2016 provides three new security features which helps to protect data.

Below there are new security features added in SQL Server 2016.

Row-Level Security (RLS)
Dynamic Data Masking (DDM)
Always Encrypted

In this part of blog, we will see use case […]

By |February 1st, 2017|Categories: Database Administration, Security and Encryption, Transact-SQL|Tags: , , , |Comments Off on New Security Features In SQL SERVER 2016 – PART 1

Customize your message using FORMATMESSAGE Function

Using FormatMessage function you can construct a message string located in sys.messages. The functionality of FORMATMESSAGE is very much same as RAISERROR statement. FORMATMESSAGE functions edits the message by substituting the supplied parameter values for placeholder variables in the message string.

Syntax:

FORMATMESSAGE ( { msg_number  | ‘ msg_string ‘ } , [ param_value [ ,…n […]

By |January 12th, 2017|Categories: Database Development, Programming, SQL Server, Transact-SQL|Tags: , |Comments Off on Customize your message using FORMATMESSAGE Function
Newsletter_Footer