This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| select * | |
| from table( | |
| dbms_xplan.display_cursor( | |
| ( SELECT max(sql_id) keep (dense_rank first order by last_active_time desc) | |
| FROM V$SQL | |
| WHERE lower(sql_text) LIKE 'select /*+ gather_plan_statistics %'), | |
| '', | |
| 'ALLSTATS ADVANCED LAST +PEEKED_BINDS' | |
| ) | |
| ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| declare | |
| v_owner varchar2(4000) := '?'; | |
| type t_varchar2_tab is table of varchar2(4000); | |
| v_tables t_varchar2_tab := t_varchar2_tab( | |
| '?', | |
| '?' | |
| ); | |
| begin | |
| for i in 1..v_tables.count loop | |
| dbms_stats.gather_table_stats( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| declare | |
| v_string varchar2(4000) := ''; | |
| begin | |
| if v_string = '' then | |
| raise_application_error(-20000, 'It''s not working!'); | |
| else | |
| raise_application_error(-20000, 'Hey, this is empty string!'); | |
| end if; | |
| end; | |
| / |
OlderNewer