Author: Yavuz Selim Kart

Listing Active Triggers in SQL Server

Hello everyone, In this section, I will talk about how to list active triggers in SQL Server. In SQL Server, in some cases, it may be necessary to list active triggers for the database. Using the code below, you can list your active triggers for your database. SELECT TAB.name AS...

Function Parses JSON in SQL Server

Hello everyone, In this article, I will try to give information about the function that parses JSON in SQL Server. In SQL Server, in some cases, you may want to parse the JSON data you have. You can easily do this using the function below. CREATE FUNCTION [dbo].[parseJSON] ( @JSON...

Missing Index Query in SQL Server

Hello everyone, In this article, I will give information about how to query the missing Index in SQL Server. Questions such as whether I have performance problems due to missing indexes in SQL Server may come to your mind. At this point, we can query the missing indexes using the...

Cursor to Remove All Tables in Selected Database in SQL Server

Hello everyone, In this article, I will give you information about removing all Tables in the selected database in SQL Server with the help of Cursor. In SQL Server, in some cases, all tables in the database may need to be removed. You can solve this operation in one go...

Finding Version in SQL Server

Hello everyone, In this article, you will learn about learning version information in SQL Server. You can learn your SQL Server version information by using the code below. SELECT CAST(SUBSTRING( CAST(SERVERPROPERTY(‘productversion’) AS VARCHAR(20)), 1, CHARINDEX(‘.’, CAST(SERVERPROPERTY(‘productversion’) AS VARCHAR(20))) – 1 ) AS INT); When you run the above code, you...

Cursor Disconnecting Database Before Detach Operation in SQL Server

Hello everyone, In this article, I will talk about the use of cursor that disconnects the database before detach in SQL Server. Actually I wrote this Cursor on a question. Thinking it might be useful to someone. While detaching in SQL Server, you may encounter errors upon connection. These errors...

Don`t copy text!