Learn How to Recover Deleted Records from SQL Server 2014

Problem Sometimes users may have numerous of databases in their SQL Server. However, while managing their database sometimes by mistake their records are deleted due to which they face a lot of issues. To maintain the workflow they need to recover deleted records from SQL Server 2014. This could be possible only with successful SQL […]

Continue Reading

Two Ways to Restore Database from MDF File in SQL Server

Ways to Restore Database from MDF File Introduction In todays decade Relational database Management system became the necessity of the organizations whether they are small level or large level. In such context SQL Server is the best and successful RDBMS which provides highly integrated services to manipulate the SQL database over the Server. As we […]

Continue Reading

SQL Script to find all the triggers defined on a database or on a single table

SQL Script to find triggers in SQL Database Sometime we need to find all the triggers defined on the database. So in this case, we can use the below SQL Query:-SELECT tbl.name as [Table Name] , trig.name as [Trigger Name] , trig.is_disabled FROM [sys].[triggers] as trig INNER JOIN sys.tables as tbl ON trig.parent_id = tbl.object_idIn […]

Continue Reading

Script to find the complete weeks within two given dates

Complete weeks within two given dates Sometimes we need to find out the complete weeks within two given dates. Below script will help in finding the complete weeks within 2 given dates. In this script, I have used below dates as exampleStartdate=2015-04-12 Enddate=2015-06-10 SET DATEFORMAT YMD if (object_id(‘tempdb..#weekdays’) is not null) drop table #weekdays Declare […]

Continue Reading