Query v$sql for sql text : V_sql « System Tables Views « Oracle PL / SQL






Query v$sql for sql text

  
SQL>
SQL> alter session set cursor_sharing=force;

Session altered.

SQL> select substr( username, 1, 1 )
  2    from all_users au2
  3   where rownum = 1;

SUBSTR(USERNAME,1,1)
------------------------------
S

1 row selected.

SQL>
SQL> select sql_text from v$sql
  2     where sql_text like 'select /* TAG */ %';

no rows selected

SQL>
SQL>

   
    
  








Related examples in the same category

1.Display the text of a cached query in the shared pool, then the execution plan.