New Statements in SQL Server 2016
One of the most annoying things in SQL Server is checking whether an object exists before it is dropped:
IF OBJECT_ID('dbo.Product', 'U') IS NOT NULL
DROP TABLE dbo.Product;
IF EXISTS (SELECT * FROM sys.triggers WHERE name = 'trProductInsert')
DROP TRIGGER trProductInsert
SQL Server 2016 CTP3 adds new DROP IF EXIST
(or DIE) syntax:
DROP FUNCTION IF EXISTS fnCount
DROP PROCEDURE IF EXISTS spReport
DROP TABLE IF EXISTS myTable
In SQL Server 2016 CTP3, the following objects can DIE:
AGGREGATE PROCEDURE TABLE
ASSEMBLY ROLE TRIGGER
VIEW RULE TYPE
DATABASE SCHEMA USER
DEFAULT SECURITY POLICY
VIEW FUNCTION SEQUENCE
COLUMN INDEX SYNONYM
CONSTRAINT
Graduated from Faculty of Electrical Engineering, Department of Computer Techniques and Informatics, University of Belgrade, Serbia.
Currently working in Microsoft as Program Manager on SQL Server product.
Member of JQuery community - created few popular plugins (four popular JQuery DataTables add-ins and loadJSON template engine).
Interests: Web and databases, Software engineering process(estimation and standardization), mobile and business intelligence platforms.