{"id":75,"date":"2022-11-09T15:20:18","date_gmt":"2022-11-09T18:20:18","guid":{"rendered":"https:\/\/kappasoft.com.br\/wiki\/?p=75"},"modified":"2022-11-09T15:20:19","modified_gmt":"2022-11-09T18:20:19","slug":"como-pegar-as-queries-antigas-no-historico","status":"publish","type":"post","link":"https:\/\/kappasoft.com.br\/wiki\/2022\/11\/09\/como-pegar-as-queries-antigas-no-historico\/","title":{"rendered":"Como pegar as queries antigas no hist\u00f3rico"},"content":{"rendered":"\n<div class=\"wp-block-codemirror-blocks-code-block code-block\"><pre class=\"CodeMirror\" data-setting=\"{&quot;showPanel&quot;:true,&quot;languageLabel&quot;:&quot;language&quot;,&quot;fullScreenButton&quot;:true,&quot;copyButton&quot;:true,&quot;mode&quot;:&quot;sql&quot;,&quot;mime&quot;:&quot;text\/x-sql&quot;,&quot;theme&quot;:&quot;material&quot;,&quot;lineNumbers&quot;:false,&quot;styleActiveLine&quot;:false,&quot;lineWrapping&quot;:false,&quot;readOnly&quot;:true,&quot;fileName&quot;:&quot;&quot;,&quot;language&quot;:&quot;SQL&quot;,&quot;maxHeight&quot;:&quot;400px&quot;,&quot;modeName&quot;:&quot;sql&quot;}\">col program for a35 \ncol module for a40\ncol event for a30\nset pages 300 lines 220\nSELECT SESSION_ID, program, module, machine, event,sql_id ,TIME_WAITED,SESSION_STATE, sample_time\nFROM  dba_hist_active_sess_history \nWHERE sample_time between to_date('24\/01\/2022 12:58:00','dd\/mm\/yyyy hh24:mi:ss') \nand  to_date('24\/01\/2022 16:13:00','dd\/mm\/yyyy hh24:mi:ss')\nand module not in ('Oracle Enterprise Manager.Metric Engine')\norder by sample_time;<\/pre><\/div>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1,2],"tags":[],"class_list":["post-75","post","type-post","status-publish","format-standard","hentry","category-banco-de-dados","category-oracle"],"_links":{"self":[{"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/posts\/75","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/comments?post=75"}],"version-history":[{"count":1,"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/posts\/75\/revisions"}],"predecessor-version":[{"id":76,"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/posts\/75\/revisions\/76"}],"wp:attachment":[{"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/media?parent=75"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/categories?post=75"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kappasoft.com.br\/wiki\/wp-json\/wp\/v2\/tags?post=75"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}