TL;DR:
If you’re using a LEFT JOIN
but filtering on the right table in the WHERE
clause, you might unintentionally turn it into an INNER JOIN
. Here’s why that happens, how to fix it, and how different databases handle it.

TL;DR:
If you’re using a LEFT JOIN
but filtering on the right table in the WHERE
clause, you might unintentionally turn it into an INNER JOIN
. Here’s why that happens, how to fix it, and how different databases handle it.
As data grows larger and more complex, optimizing for performance and scalability becomes essential. Partitioning is one of the most powerful strategies for managing big datasets efficiently. If you’ve come across a column like p_date
in an SQL query, it often signals the use of table partitioning. But what does that mean, and how is it different from traditional databases?
SQL window functions like LEAD
and LAG
are indispensable tools for business intelligence and data analysis, enabling professionals to uncover trends, track changes, and derive actionable insights. In this guide, we’ll break down how these functions work and demonstrate their real-world applications in SQL-driven analytics.
SQL window functions are one of the most powerful tools for performing calculations across a defined range of rows while maintaining access to individual row-level details. Unlike aggregate functions that collapse rows into a single value, window functions allow you to perform calculations over a subset of rows (a window) while preserving the original row structure.
Continue readingIf you work with data, SQL functions are your toolkit for unlocking powerful insights. Whether you’re crafting detailed reports or uncovering business-changing analytics, SQL is the backbone for data doers in every industry. This guide explores 27 SQL functions that every data analyst, data engineer, or analytics enthusiast should know. These functions are grouped into five categories for easier understanding and practical use.
Continue readingI recently encountered a project that uses HIVE table, coming from microsoft sql , mysql background, I had a little struggle with different sql syntax and behavior, thought I’d write this article on some common SQL to Hive conversions in case you are ever in similar situation.
Continue readingIn the world of databases, SQL is a foundational language that serves as the backbone for interacting with relational databases. However, when delving deeper into SQL, you will come across terms like ANSI SQL and T-SQL, which may seem confusing at first. In this article, we’ll explore what SQL, ANSI SQL, and T-SQL are, how they differ, and their specific use cases.
Continue readingData warehousing and business intelligence are crucial for modern enterprises, enabling them to make informed decisions based on historical data. One key aspect of data warehousing is handling changing data over time, especially when tracking historical changes in dimensions. This is where Slowly Changing Dimensions (SCD) come into play. In this blog post, we’ll delve into what SCDs are, the different types of SCDs, and how to implement them effectively.
Continue reading