Factless fact table

There are different types of fact tables in a data warehouse, such as Transaction, Periodic Snapshot, and Accumulating Transactions. However, a Factless fact table is distinct from other fact tables…

Read more »

How to delete duplicate rows from a table in SQL

Duplicate records can result in unintended outcomes when working with data. Despite data professionals disliking it, this issue is often encountered in data warehouse systems. When loading data from sources…

Read more »

Impact of using local variable in Stored Procedure

Preparing an optimal execution plan for a given SQL query is crucial, and the Query Optimizer’s ability to do so heavily relies on the accuracy and freshness of the statistics…

Read more »

Additive, non-additive and semi additive facts in data warehouse fact table

In a data warehouse fact table, fact can be classified as additive, semi additive or non-additive based on their characteristics. Additive facts are measures that can be aggregated by ALL…

Read more »

DROP multiple tables using a single DROP statement

The DROP TABLE command can also be used to drop multiple tables in a single statement. Example, Separate each table with a comma in the DROP TABLE statement to drop…

Read more »

How to Convert Seconds to “HH:MM:SS” format in TSQL

Presenting the time/duration in HH:MM:SS format is important for good readability. There are situations where the duration of an event needs to be calculated between time intervals. The difference can…

Read more »

Synonym in SQL Server

Synonym A synonym is an alias or an alternative name given to the other objects in the database. The alternative name can be used to refer to the underlying objects…

Read more »

Can TRUNCATE be rolled back in SQL Server?

A database transaction, by definition, must be atomic (it must either complete in its entirety or do not affect whatsoever), consistent, isolated, and durable. These four properties are commonly referred…

Read more »

How to find a column is updated.

In application development, there are situations where an action is driven based on a change in data. A trigger can be used to perform an action based on the data…

Read more »

Grant permission to Integration Service Catalog folder

People often confused that having access to SSISDB will also provide access to the Integration Service Catalog folders but permission for the folder is handled separately. The following code can…

Read more »