Skip to content
Insane DBA

Databases@Powered by Passion

  • HomeHome Page
  • OracleBlog posts about Oracle
    • Autonomous DBBlog posts about Autonomous Databases
    • Performance
    • Update
    • Security
    • Exadata
    • Spatial
    • Flashback
    • Backup&RecoveryBlog posts about Backup and Recovery
  • PostgreSQLBlog posts about PostgreSQL
  • OtherBlog posts about other content
    • MongoDB
    • MariaDB
  • About MeWho is InsaneDBA?
  • Aggregate Function Behaviors with No Matching Rows

    How SQL Handles No Matching Rows in Aggregation

    17 May 2025 11:25

    —

    by

    Osman DİNÇ
    Databases, Oracle, Performance

    SQL aggregation queries behave differently with and without a GROUP BY clause, particularly when no rows match. A query with GROUP BY returns no rows, while without it, a NULL value appears. To align results with expectations, using COALESCE() can return 0 instead of NULL for sums in such cases.


  • NO_DATA_FOUND Not Raised

    Why NO_DATA_FOUND Behavior Differs in SQL and PL/SQL

    17 May 2025 11:22

    —

    by

    Osman DİNÇ
    Databases, Oracle, Performance

    Many Oracle developers overlook that a PL/SQL function’s SELECT INTO statement will raise a NO_DATA_FOUND exception in PL/SQL but silently return NULL in SQL when no rows are found. This difference can lead to logic bugs. Understanding this behavior is essential for developing robust code and avoiding debugging challenges.


  • Scalar Subquery Caching

    Scalar Subquery Caching Behavior in a SQL Statement

    17 May 2025 11:20

    —

    by

    Osman DİNÇ
    Databases, Oracle, Performance

    Scalar subquery caching is an Oracle SQL optimization technique that improves performance by storing results of scalar subqueries. This technique reduces redundant evaluations and recursive function calls. However, caution is advised when wrapping PL/SQL functions in these queries, as it may lead to unexpected results, particularly with functions needs unique values. Understanding this caching appropriately yields significant benefits.


  • NVL vs DECODE

    NVL and DECODE: Lazy vs Eager Evaluation

    17 May 2025 11:19

    —

    by

    Osman DİNÇ
    Databases, Oracle, Performance

    The blog post discusses the behaviors of Oracle’s NVL and DECODE functions regarding NULL values. While NVL employs eager evaluation, executing all arguments regardless of necessity, DECODE uses lazy evaluation, only evaluating the second argument when needed. This difference can lead to performance issues or unexpected errors.


  • Common SQL Pitfalls

    Common SQL and PL/SQL Pitfalls: Insights from Real-World Experience

    17 May 2025 11:18

    —

    by

    Osman DİNÇ
    Databases, Oracle, Performance

    The content highlights key Oracle SQL and PL/SQL behaviors that, while seemingly simple, often result in unexpected issues in production environments. It emphasizes the importance of revisiting foundational topics to avoid bugs and performance problems. Through a series of blog posts, real-world examples are shared to assist others and enhance understanding of crucial functionalities, aiming to support the Oracle community effectively.


  • Oracle Hash Partitioning

    Oracle Hash Partitioning : Benefits and Best Practices

    9 May 2025 13:52

    —

    by

    Osman DİNÇ
    Databases, Oracle, Performance

    Hash partitioning enhances database management and performance by evenly distributing data across partitions, crucial for handling high concurrency. However, choosing an appropriate partition key is vital to avoid skewed data distribution. Proper use of partition keys allows for efficient query performance and reduces contention in both single-instance and RAC environments.


←Previous Page
1 2 3 4 5 … 16
Next Page→
Osman DİNÇ Avatar

Osman DİNÇ – About Me

  • LinkedIn
  • Bluesky
  • GitHub
  • X
  • RSS Feed
Follow Insane DBA in Feedly


Search this blog


Categories


  • April 2026 (1)
  • March 2026 (1)
  • January 2026 (1)
  • December 2025 (1)
  • November 2025 (1)
  • October 2025 (1)
  • July 2025 (1)
  • June 2025 (3)
  • May 2025 (9)
  • April 2025 (4)
  • March 2025 (1)
  • February 2025 (2)
  • January 2025 (2)
  • December 2024 (9)
  • November 2024 (6)
  • October 2024 (3)
  • September 2024 (3)
  • August 2024 (5)
  • July 2024 (2)
  • June 2024 (6)
  • May 2024 (4)
  • April 2024 (3)
  • March 2024 (2)
  • December 2023 (1)
  • November 2023 (4)
  • October 2023 (8)
  • June 2023 (1)
  • May 2023 (1)
  • April 2023 (1)
  • January 2023 (1)
  • December 2022 (5)
  • September 2022 (1)
  • March 2022 (1)
  • February 2022 (1)

Insane DBA

Connect to Me

  • LinkedIn
  • Bluesky
  • GitHub
  • Reddit
  • X
  • Mail
Flag Counter
  • Subscribe Subscribed
    • Osman’s DBlog
    • Join 43 other subscribers
    • Already have a WordPress.com account? Log in now.
    • Osman’s DBlog
    • Subscribe Subscribed
    • Sign up
    • Log in
    • Report this content
    • View site in Reader
    • Manage subscriptions
    • Collapse this bar