File tree Expand file tree Collapse file tree 1 file changed +35
-0
lines changed Expand file tree Collapse file tree 1 file changed +35
-0
lines changed Original file line number Diff line number Diff line change
1
+ --
2
+ -- Author: Hari Sekhon
3
+ -- Date: 2024-10-17 23:06:57 +0400 (Thu, 17 Oct 2024)
4
+ --
5
+ -- vim:ts=4:sts=4:sw=4:et:filetype=sql
6
+ --
7
+ -- https://github.com/HariSekhon/SQL-scripts
8
+ --
9
+ -- License: see accompanying Hari Sekhon LICENSE file
10
+ --
11
+ -- If you're using my code you're welcome to connect with me on LinkedIn and optionally send me feedback to help steer this or other code I publish
12
+ --
13
+ -- https://www.linkedin.com/in/HariSekhon
14
+ --
15
+
16
+ -- Oracle - Show User Sessions Using Temporary Tablespace
17
+ --
18
+ -- Check there are none before dropping an old temp tablespace file to avoid disruptions
19
+ --
20
+ -- Tested on Oracle 19c
21
+
22
+ SELECT
23
+ s .sid ,
24
+ s .username ,
25
+ t .tablespace ,
26
+ t .blocks ,
27
+ t .segfile # ,
28
+ t .segblk # ,
29
+ t .contents ,
30
+ t .sql_id
31
+ FROM
32
+ v$sort_usage t,
33
+ v$session s
34
+ WHERE
35
+ t .session_addr = s .saddr ;
You can’t perform that action at this time.
0 commit comments