{"id":14304,"date":"2019-12-21T05:57:52","date_gmt":"2019-12-21T05:57:52","guid":{"rendered":"https:\/\/dbtut.com\/?p=14304"},"modified":"2019-12-23T07:18:36","modified_gmt":"2019-12-23T07:18:36","slug":"sql-profiles-and-baselines","status":"publish","type":"post","link":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/","title":{"rendered":"SQL Profiles and Baselines"},"content":{"rendered":"<p>Being a DBA we must know the difference between the SQL profile and the baselines. To start with we know that optimizer uses the information like gather stats of objects environments and bind variables to choose the best plan for the SQL execution .<\/p>\n<p>In some scenarios there are some defects in these inputs or the optimizer choose a not so good plan by it own.<\/p>\n<h3>What is SQL Profiles?<\/h3>\n<p>SQL profiles contains the information that solve the above problems. When we use gather stats and bind variable with the SQL profile, a SQL profile helps the optimizer to minimize the mistakes and more likely to choose the optimal plan for the SQL execution.<\/p>\n<h3>What is SQL Baselines?<\/h3>\n<p>A SQL baselines as the name suggests it creates a baseline for the accepted plans. when a query is parsed by the optimizer it will choose the best plan from the accepted baselines. If a different plan is found by the optimizer during the run of the SQL statement it will add the plan to the plan history, but it will not use the execution plan to execute the SQL statement until and unless it is verified to perform better than the existing plan.<\/p>\n<h3>Difference Between SQL Profiles and SQL Baselines<\/h3>\n<p>SQL profiles only helps the optimizer to choose the better plan providing some additional stats and information but it does not\u00a0 force the optimizer for any specific plan . Because of this, SQL profiles can be shared between the different environment a example for which is given below in the post.<\/p>\n<p>Where as the SQL baselines constrain the optimizer to choose from the accepted set of plans. The CBO approach will be used but it will only apply to the only accepted plans from the baselines.<\/p>\n<h3>So what we choose SQL Profiles or the Baselines?<\/h3>\n<p>Well the answer to the above question is based upon the approach and what you want to achieve. You should use SQL profiles if you just want to help the optimizer in its costing process this approach can be very useful in cases where you want to system to adapt quickly to changes like new object stats.<\/p>\n<p>SQL baselines should be used where you specifically want to control which plans should be used by the optimizer.<\/p>\n<h4>SPM creating SQL plan baselines<\/h4>\n<p>What is SPM and how it does affect the performance of your environment.<\/p>\n<p>Suddenly the execution plan for your SQL has been changed and you are facing the slowness, there are many parameters which can affect this like stale stats of the objects or changes in the few optimizer related parameters.<\/p>\n<p>All a DBA want is that plan should only change when they result in the performance gains else the optimizer should maintain the status quo. In other words, the optimizer should not pick bad plans.<\/p>\n<h4><strong>SQ<\/strong>L Plan Management<\/h4>\n<p>For a set of SQL statements SPM allows the database to maintain the stable performance these SQL statements which are managed by SPM are called as managed SQL statements. SPM mainly helps in maintaining the two objectives<\/p>\n<ul>\n<li>Prevent the managed SQL statements from performance degradation in case there are database system changes<\/li>\n<li>And if there are changes in the database it offers the managed SQL statements to accept the performance improvements gracefully.<\/li>\n<\/ul>\n<p>SPM can be enabled manually, or it can be left to work automatically. By using the manual mode, we can control if we want to do it partially or wholly. SPM maintains a plan history of these managed SQL statements on disk consisting of different execution plan generated for each SQL statements and SPM helps in enabling the detection of plan changes of these SQL statements.<\/p>\n<p>A higher version of oracle optimizer is called as SPM aware optimizer who access and manages this information which is stored in the repository called as SQL management base (SBM).<\/p>\n<p>SPM Aware optimizer uses the information from plan history to determine whether the current execution plan generated by the cost best method is a brand new or not. The brand-new plan might have the potential to cause the performance degradation until and unless its verified. For this very reason the SPM aware optimizer does not chose the brand-new execution plan based upon the cost. It chooses the plan form a set of accepted plans which is verified to not to cause the performance degradation and these set of set of accepted set of plans is called as SQL baselines. SQL plan base lines are the subset of plan history.<\/p>\n<p>The brand-new plan will be added to the plan history as a not good or non-accepted plan. Later using the SPM utility, we can verify the plan if it shows still bad performance or it provides a performance improvements then it can be added to the plan history as accepted plan.<\/p>\n<p>There are multiple ways to create the SQL plan baselines. I have described tow which are widely used.<\/p>\n<h3>Creating SQL plan baselines from cursor cache<\/h3>\n<p>Lets just say we have a query with a SQL_ID = abc123def and the Plan hash value as : 123456789<\/p>\n<p>The below procedure will create a SQL baseline.<\/p>\n<pre class=\"lang:default decode:true\">begin\ndbms_output.put_line(\ndbms_spm.load_plans_from_cursor_cache\n( sql_id =&gt; \u2018abc123def\u2019,\nplan_hash_value =&gt; 123456789)\n);\nend;\n\/.<\/pre>\n<p>If you need to create the baselines for more than one SQL statements according to the text you can use :<\/p>\n<pre class=\"lang:default decode:true \">SQL&gt; exec :pls := dbms_spm.load_plans_from_cursor_cache( -\nattribute_name =&gt; 'SQL_TEXT', -\nattribute_value =&gt; 'select%p.prod_name%');<\/pre>\n<h2>Creating SQL plan baselines using a staging table<\/h2>\n<p>Using this method, we can share the SQL baselines from one system to another system as this method loads the profiles in staging and that can be imported to the target environment.<\/p>\n<p>On the source system where we have the SQL baselines which can be created from the above method, we need to create a staging table so the SQL baselines can be packed into it.<\/p>\n<pre class=\"lang:default decode:true \">SQL&gt; exec dbms_spm.create_stgtab_baseline(table_name =&gt; 'AMIT', -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 table_owner =&gt; 'VS');\nPL\/SQL procedure successfully completed.\n\nSQL&gt; exec :pls := dbms_spm.pack_stgtab_baseline( -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 table_name =&gt; 'AMIT', -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 table_owner =&gt; 'VS', -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 sql_text =&gt; 'update%p.prod_name%');<\/pre>\n<p>The table named AMIT created is a normal table which can be easily exported and imported\u00a0 using the Datapump utility.<\/p>\n<p>On the target system now we need to unpack so that the SQL baselines can be created.<\/p>\n<pre class=\"lang:default decode:true \">SQL&gt; exec :pls := dbms_spm.unpack_stgtab_baseline( -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 table_name =&gt; 'AMIT', -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 table_owner =&gt; 'VS', -\n&gt;\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 sql_text =&gt; 'select%p.prod_name%');<\/pre>\n<p>We can use the same table to pack the different baselines and selectively unpack only a subset on the target system.<\/p>\n<p>SQL baselines can be created automatically by setting the parameter optimizer_capture_sql_plan_baselines to true<\/p>\n<div class=\"pvc_clear\"><\/div>\n<p id=\"pvc_stats_14304\" class=\"pvc_stats all  \" data-element-id=\"14304\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"https:\/\/dbtut.com\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p>\n<div class=\"pvc_clear\"><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Being a DBA we must know the difference between the SQL profile and the baselines. To start with we know that optimizer uses the information like gather stats of objects environments and bind variables to choose the best plan for the SQL execution . In some scenarios there are some defects in these inputs or &hellip;<\/p>\n<div class=\"pvc_clear\"><\/div>\n<p id=\"pvc_stats_14304\" class=\"pvc_stats all  \" data-element-id=\"14304\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"https:\/\/dbtut.com\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p>\n<div class=\"pvc_clear\"><\/div>\n","protected":false},"author":481,"featured_media":14316,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_uf_show_specific_survey":0,"_uf_disable_surveys":false,"footnotes":""},"categories":[4],"tags":[6835,6839,6847,6834,6838,6833,6846,6841,6859,6856,1498,6831,6837,6832,6836,6861,6830,6840,6849,6855,6857,6858,6852,6844,6850,6853,6854,6842,6851,6860],"class_list":["post-14304","post","type-post","status-publish","format-standard","has-post-thumbnail","","category-oracle","tag-create-sql-plan","tag-create-sql-plan-baselines","tag-create-sql-plan-baselines-using-a-staging-table","tag-creating-sql-plan","tag-creating-sql-plan-baselines","tag-creating-sql-plan-baselines-from-cursor-cache","tag-creating-sql-plan-baselines-using-a-staging-table","tag-difference-between-sql-profiles-and-sql-baselines","tag-how-do-you-optimize-a-query","tag-how-does-a-profiler-work","tag-oracle","tag-spm","tag-spm-creating-sql-plan-baselines","tag-sql-baselines","tag-sql-plan-management","tag-sql-plan-management-in-oracle","tag-sql-profile","tag-sql-profiles-or-sql-baselines","tag-sql-profiles-vs-sql-plan-baselines","tag-what-is-a-profiler-in-sql","tag-what-is-a-sql-plan","tag-what-is-profile-in-database","tag-what-is-sql-baseline-in-oracle","tag-what-is-sql-baselines","tag-what-is-sql-plan-baseline","tag-what-is-sql-plan-management","tag-what-is-sql-profile-and-baseline","tag-what-is-sql-profiles","tag-what-is-sql-profiling-in-oracle","tag-what-is-the-difference-between-sql-profiles-and-sql-plan-baselines"],"aioseo_notices":[],"a3_pvc":{"activated":true,"total_views":3308,"today_views":0},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.9 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>SQL Profiles and Baselines - Database Tutorials<\/title>\n<meta name=\"description\" content=\"SQL Profiles and Baselines\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"SQL Profiles and Baselines - Database Tutorials\" \/>\n<meta property=\"og:description\" content=\"SQL Profiles and Baselines\" \/>\n<meta property=\"og:url\" content=\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\" \/>\n<meta property=\"og:site_name\" content=\"Database Tutorials\" \/>\n<meta property=\"article:published_time\" content=\"2019-12-21T05:57:52+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2019-12-23T07:18:36+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png\" \/>\n\t<meta property=\"og:image:width\" content=\"939\" \/>\n\t<meta property=\"og:image:height\" content=\"549\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Amit Vashishth\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Amit Vashishth\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\"},\"author\":{\"name\":\"Amit Vashishth\",\"@id\":\"https:\/\/dbtut.com\/#\/schema\/person\/498d05a2429aa44b0ee5e0707bfb8315\"},\"headline\":\"SQL Profiles and Baselines\",\"datePublished\":\"2019-12-21T05:57:52+00:00\",\"dateModified\":\"2019-12-23T07:18:36+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\"},\"wordCount\":1025,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/dbtut.com\/#organization\"},\"image\":{\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png\",\"keywords\":[\"Create SQL plan\",\"Create SQL plan baselines\",\"Create SQL plan baselines using a staging table\",\"Creating SQL plan\",\"Creating SQL plan baselines\",\"Creating SQL plan baselines from cursor cache\",\"Creating SQL plan baselines using a staging table\",\"Difference Between SQL Profiles and SQL Baselines\",\"How do you optimize a query?\",\"How does a profiler work?\",\"oracle\",\"SPM\",\"SPM creating SQL plan baselines\",\"SQL BAselines\",\"SQL Plan Management\",\"SQL Plan Management in Oracle\",\"SQL Profile\",\"SQL Profiles or SQL Baselines\",\"SQL Profiles vs SQL Plan Baselines\",\"What is a profiler in SQL?\",\"What is a SQL plan?\",\"What is profile in database?\",\"What is SQL baseline in Oracle?\",\"What is SQL Baselines?\",\"What is SQL plan baseline?\",\"What is SQL Plan management?\",\"What is SQL profile and baseline?\",\"What is SQL Profiles\",\"What is SQL Profiling in Oracle?\",\"What is the difference between SQL Profiles and SQL Plan Baselines\"],\"articleSection\":[\"ORACLE\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\",\"url\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\",\"name\":\"SQL Profiles and Baselines - Database Tutorials\",\"isPartOf\":{\"@id\":\"https:\/\/dbtut.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png\",\"datePublished\":\"2019-12-21T05:57:52+00:00\",\"dateModified\":\"2019-12-23T07:18:36+00:00\",\"description\":\"SQL Profiles and Baselines\",\"breadcrumb\":{\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage\",\"url\":\"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png\",\"contentUrl\":\"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png\",\"width\":939,\"height\":549},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/dbtut.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"SQL Profiles and Baselines\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/dbtut.com\/#website\",\"url\":\"https:\/\/dbtut.com\/\",\"name\":\"Database Tutorials\",\"description\":\"MSSQL, Oracle, PostgreSQL, MySQL, MariaDB, DB2, Sybase, Teradata, Big Data, NOSQL, MongoDB, Couchbase, Cassandra, Windows, Linux\",\"publisher\":{\"@id\":\"https:\/\/dbtut.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/dbtut.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/dbtut.com\/#organization\",\"name\":\"dbtut\",\"url\":\"https:\/\/dbtut.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/dbtut.com\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/dbtut.com\/wp-content\/uploads\/2021\/02\/dbtutlogo.jpg\",\"contentUrl\":\"https:\/\/dbtut.com\/wp-content\/uploads\/2021\/02\/dbtutlogo.jpg\",\"width\":223,\"height\":36,\"caption\":\"dbtut\"},\"image\":{\"@id\":\"https:\/\/dbtut.com\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/dbtut.com\/#\/schema\/person\/498d05a2429aa44b0ee5e0707bfb8315\",\"name\":\"Amit Vashishth\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/dbtut.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/1151b8ba4366b28f37b7864d09bc41e952f55c1e541e29bc6b499dc55f8a502d?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/1151b8ba4366b28f37b7864d09bc41e952f55c1e541e29bc6b499dc55f8a502d?s=96&d=mm&r=g\",\"caption\":\"Amit Vashishth\"},\"url\":\"https:\/\/dbtut.com\/index.php\/author\/amitvashishth\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"SQL Profiles and Baselines - Database Tutorials","description":"SQL Profiles and Baselines","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/","og_locale":"en_US","og_type":"article","og_title":"SQL Profiles and Baselines - Database Tutorials","og_description":"SQL Profiles and Baselines","og_url":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/","og_site_name":"Database Tutorials","article_published_time":"2019-12-21T05:57:52+00:00","article_modified_time":"2019-12-23T07:18:36+00:00","og_image":[{"width":939,"height":549,"url":"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png","type":"image\/png"}],"author":"Amit Vashishth","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Amit Vashishth","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#article","isPartOf":{"@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/"},"author":{"name":"Amit Vashishth","@id":"https:\/\/dbtut.com\/#\/schema\/person\/498d05a2429aa44b0ee5e0707bfb8315"},"headline":"SQL Profiles and Baselines","datePublished":"2019-12-21T05:57:52+00:00","dateModified":"2019-12-23T07:18:36+00:00","mainEntityOfPage":{"@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/"},"wordCount":1025,"commentCount":0,"publisher":{"@id":"https:\/\/dbtut.com\/#organization"},"image":{"@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage"},"thumbnailUrl":"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png","keywords":["Create SQL plan","Create SQL plan baselines","Create SQL plan baselines using a staging table","Creating SQL plan","Creating SQL plan baselines","Creating SQL plan baselines from cursor cache","Creating SQL plan baselines using a staging table","Difference Between SQL Profiles and SQL Baselines","How do you optimize a query?","How does a profiler work?","oracle","SPM","SPM creating SQL plan baselines","SQL BAselines","SQL Plan Management","SQL Plan Management in Oracle","SQL Profile","SQL Profiles or SQL Baselines","SQL Profiles vs SQL Plan Baselines","What is a profiler in SQL?","What is a SQL plan?","What is profile in database?","What is SQL baseline in Oracle?","What is SQL Baselines?","What is SQL plan baseline?","What is SQL Plan management?","What is SQL profile and baseline?","What is SQL Profiles","What is SQL Profiling in Oracle?","What is the difference between SQL Profiles and SQL Plan Baselines"],"articleSection":["ORACLE"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/","url":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/","name":"SQL Profiles and Baselines - Database Tutorials","isPartOf":{"@id":"https:\/\/dbtut.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage"},"image":{"@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage"},"thumbnailUrl":"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png","datePublished":"2019-12-21T05:57:52+00:00","dateModified":"2019-12-23T07:18:36+00:00","description":"SQL Profiles and Baselines","breadcrumb":{"@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#primaryimage","url":"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png","contentUrl":"https:\/\/dbtut.com\/wp-content\/uploads\/2019\/12\/Ads\u0131z-13.png","width":939,"height":549},{"@type":"BreadcrumbList","@id":"https:\/\/dbtut.com\/index.php\/2019\/12\/21\/sql-profiles-and-baselines\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/dbtut.com\/"},{"@type":"ListItem","position":2,"name":"SQL Profiles and Baselines"}]},{"@type":"WebSite","@id":"https:\/\/dbtut.com\/#website","url":"https:\/\/dbtut.com\/","name":"Database Tutorials","description":"MSSQL, Oracle, PostgreSQL, MySQL, MariaDB, DB2, Sybase, Teradata, Big Data, NOSQL, MongoDB, Couchbase, Cassandra, Windows, Linux","publisher":{"@id":"https:\/\/dbtut.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/dbtut.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/dbtut.com\/#organization","name":"dbtut","url":"https:\/\/dbtut.com\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/dbtut.com\/#\/schema\/logo\/image\/","url":"https:\/\/dbtut.com\/wp-content\/uploads\/2021\/02\/dbtutlogo.jpg","contentUrl":"https:\/\/dbtut.com\/wp-content\/uploads\/2021\/02\/dbtutlogo.jpg","width":223,"height":36,"caption":"dbtut"},"image":{"@id":"https:\/\/dbtut.com\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/dbtut.com\/#\/schema\/person\/498d05a2429aa44b0ee5e0707bfb8315","name":"Amit Vashishth","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/dbtut.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/1151b8ba4366b28f37b7864d09bc41e952f55c1e541e29bc6b499dc55f8a502d?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1151b8ba4366b28f37b7864d09bc41e952f55c1e541e29bc6b499dc55f8a502d?s=96&d=mm&r=g","caption":"Amit Vashishth"},"url":"https:\/\/dbtut.com\/index.php\/author\/amitvashishth\/"}]}},"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/posts\/14304","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/users\/481"}],"replies":[{"embeddable":true,"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/comments?post=14304"}],"version-history":[{"count":0,"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/posts\/14304\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/media\/14316"}],"wp:attachment":[{"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/media?parent=14304"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/categories?post=14304"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dbtut.com\/index.php\/wp-json\/wp\/v2\/tags?post=14304"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}