SELECT
s.sid sid
, s.serial# serial
,sa.sql_fulltext
, to_char(s.logon_time,'dd/mm/yyyy hh24:mi:ss') slogon_time
, lpad(s.status,9) session_status
, lpad(s.username,14) oracle_username
, lpad(s.osuser,12) os_username
, lpad(p.spid,7) os_pid
, s.program session_program
--, SUBSTR(sa.sql_text, 1, 600) current_sql
FROM
v$process p
, v$session s
, v$sqlarea sa
WHERE
p.addr (+) = s.paddr
AND s.sql_address = sa.address(+)
AND s.sql_hash_value = sa.hash_value(+)
AND s.username='XXTAB'
or
SELECT a.sql_text
FROM v$sqltext a,
v$session b
WHERE a.address = b.sql_address
AND a.hash_value = b.sql_hash_value
AND b.username = 'XXTAB'
ORDER BY a.piece;
Screenshot
-------------