Heap
What is a SQL Server Heap? Before we get into the different types of indexes that are available in SQL Server we should first describe the basic structure of a table. Tables with no clustered…
What is a SQL Server Heap? Before we get into the different types of indexes that are available in SQL Server we should first describe the basic structure of a table. Tables with no clustered…
Stored procedures are basically a list of sql statement that needs to be executed. it works a function in our programming languages. Like you create a function and call it when ever you want. So…
Triggers are specail stored procedures that execute automatically based on an event. There are 3 types of triggers: DML (Data-Manipulating Language) Triggers: work when the event of DMLs are invoked like Insertion, Updating, Deletion etc…
Index basically is a way to find the relevant data row faster. so sql provides us the features of using indexes. There are two types of indexes basically: Clustered Index: A clustered index is one…
where ever we use a select statement we get some kind of resultset. in order to save our time sql provides a functionality to save such queries as views so Views are basically stored queries.…
Introduction to Dynamic SQL Dynamic SQL is a programming technique that allows you to construct SQL statements dynamically at runtime. It allows you to create more general purpose and flexible SQL statement because the full…
SQL Server THROW statement overview The THROW statement raises an exception and transfers execution to a CATCH block of a TRY CATCH construct. The following illustrates the syntax of the THROW statement: 123 THROW [ error_number , message , state ]; In this syntax: error_number The error_number is an…
If you develop a new application, you should use the THROW statement instead. SQL Server RAISEERROR statement overview The RAISERROR statement allows you to generate your own error messages and return these messages back to the application using the same format…
SQL Server TRY CATCH overview The TRY CATCH construct allows you to gracefully handle exceptions in SQL Server. To use the TRY CATCH construct, you first place a group of Transact-SQL statements that could cause an exception in a BEGIN TRY…END TRY block…
SQL works based on set e.g., SELECT statement returns a set of rows which is called a result set. However, sometimes, you may want to process a data set on a row by row basis. This is…