About 54,500 results
Open links in new tab
  1. SQL CASE Expression - W3Schools

    The CASE expression is used to define different results based on specified conditions in an SQL statement. The CASE expression goes through the conditions and stops at the first match (like an if …

  2. CASE (Transact-SQL) - SQL Server | Microsoft Learn

    Nov 18, 2025 · CASE can be used in any statement or clause that allows a valid expression. For example, you can use CASE in statements such as SELECT, UPDATE, DELETE and SET, and in …

  3. How to Use the CASE Statement in SQL (With Examples)

    Learn how to use the SQL `CASE` statement to implement conditional logic efficiently. Explore its syntax, use cases, best practices, and performance considerations.

  4. SQL CASE WHEN with Multiple Conditions - Interview Query

    Mar 17, 2026 · By the end, you’ll know how to write and optimize case when in sql logic—including how to use a case statement with multiple conditions effectively in real-world queries.

  5. CASE Statement in SQL Examples - SQL Server Tips

    Apr 20, 2021 · This tip will teach you when and how you can use CASE in T-SQL statements with several code examples to give you a better understanding.

  6. SQL CASE Statement - GeeksforGeeks

    Feb 12, 2026 · The SQL CASE statement is used to add conditional logic inside SQL queries. It checks conditions one by one and returns a value as soon as a matching condition is found.

  7. SQL CASE WHEN: The Complete Guide With Examples (2026)

    Learn SQL CASE WHEN with practical examples. Master simple CASE, searched CASE, CASE with aggregates, and common patterns every SQL developer needs.

  8. CASE statement in SQL

    Apr 1, 2019 · This article gives overview of CASE statement in SQL along with use cases and examples.

  9. How to Use CASE statement in SQL: Explained with Examples

    Jun 28, 2023 · In summary, the SQL case statement enables users to flexibly handle conditional logic when querying data in a simple, readable format. Understanding the basic syntax and working with …

  10. SQL CASE Expression

    This tutorial shows you how to use two forms of SQL CASE expressions including simple CASE and searched CASE expressions.