Home | 簡體中文 | 繁體中文 | 雜文 | 打賞(Donations) | Github | OSChina 博客 | 雲社區 | 雲棲社區 | Facebook | Linkedin | 知乎專欄 | 視頻教程 | About

82.3. session

查看用戶正在執行的SQL

		
SQL> SELECT osuser, username, sql_text from v$session a, v$sqltext b where a.sql_address =b.address order by address, piece;

OSUSER			       USERNAME 		      SQL_TEXT
------------------------------ ------------------------------ ----------------------------------------------------------------
oracle			       SYSMAN			      BEGIN EMD_NOTIFICATION.QUEUE_READY(:1, :2, :3); END;
oracle			       SYS			      SELECT osuser, username, sql_text from v$session a, v$sqltext b
oracle			       SYS			       where a.sql_address =b.address order by address, piece
linea			       Neo			      UPDATE gt_scheduler_config SET report_date = TO_DATE(:1 ,'yyyy-M
linea			       Neo			      M-dd HH24:mi:ss') WHERE id = :2
		
		
		
SQL> select sid,username,sql_text from v$session a,v$sqltext_with_newlines b where a.SQL_ADDRESS=b.ADDRESS;

       SID USERNAME			  SQL_TEXT
---------- ------------------------------ ----------------------------------------------------------------
       177 SYSMAN			  BEGIN EMD_NOTIFICATION.QUEUE_READY(:1, :2, :3); END;
	95 SYS				  lines b where a.SQL_ADDRESS=b.ADDRESS
	95 SYS				  select sid,username,sql_text from v$session a,v$sqltext_with_new