Home › Discussions › Questions & Answers › Detecting High Parsing Due to SQL Literals

Detecting High Parsing Due to SQL Literals

Avatar photoCustomer Questions & Answers 5 replies

We suspect we have custom SQL being executed repeatedly that uses literals instead of bind variables, causing unnecessary parsing overhead. How can I use Blitz Report to identify these duplicate SQL statements in the Shared Pool?

5 replies

  • Support Enginatics

    You can use the DBA SGA SQL Performance Summary report. Set the parameter ‘Literals Duplication Count’ to a value greater than zero to display all SQL statements that are duplicated at least that number of times due to literal usage.

  • If I find such SQL, what is the best practice recommendation for developers using parameters in Blitz Reports to avoid this issue in the future?

  • Support Enginatics

    Blitz Report strongly recommends using bind variables for parameterization to avoid performance issues associated with optional parameters coded as `column_name=nvl(:bind_variable, column_name)`. For parameters, always leverage bind variables unless you specifically need to enforce reparsing using the placeholder “.

  • If I need to identify which report parameters are incorrectly set up with a bind variable name that duplicates standard Oracle keywords, is there a validation report?

  • Support Enginatics

    While not directly checking against Oracle reserved words, the Blitz Report Parameter Bind Variable Validation report helps check which bind variables were assigned to which Blitz Report parameter, useful if the same bind variable name is incorrectly used in different parameters.

  • You must be logged in to reply to this post.