Database Administration (MOSC)

MOSC Banner

How to get sqltext from sqlid, when many sqls of same id are running?

I have many sqls of the same id running, so this doesn't work. I get duplicated lines.

select address, SQL_TEXT fulltext
from gv$sqltext
where sql_id='1vb5xdmb3zgy5'
order by PIECE;


Anyone know of a better way?

Or Perhaps I should add another condition to the WHERE clause, like the 'ADDRESS' column?


thanks

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center