Skip to content

Commit 1baaf45

Browse files
committed
Wed Feb 10 08:19:08 CST 2016
1 parent 7801618 commit 1baaf45

File tree

5 files changed

+29
-0
lines changed

5 files changed

+29
-0
lines changed

README.md

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,30 @@
11
# Oracle_SQL_Scripts
2+
3+
SQL Scripts Related to Oracle. Most of them work on 10g+ and some one 12c. There are some scripts that get information from Recovery Catalog as well.
4+
5+
Please note some script have been taken from others who have opened sourced it (for example the more popular ones like snapper from Tanel and xplan_ash from Randolf) and some are my own. This is just a curated list that I have put together that I use from day to day.
6+
7+
Due to the sheer number of scripts, it was hard for me to remember name of every single script to I created another script(help.sql) to keep track of all the other script.
8+
9+
Once logged into a database(10g+), you can run @help.sql as shown below. Here I am looking for anything(like statement) that has "sess" in the script name.
10+
11+
![alt text](screenshots/pic1.png "Sample run of help.sql file")
12+
13+
Quick description of what each column mean above.
14+
MY SCRIPT NAME = obviously the script name itself
15+
DESCRIPTION = short description of what the script is suppose to do
16+
INPUT = any input required when running the script. In the above screen shot, if we were to run "perf_session_wait", we would need to pass in the session ID(SID)
17+
18+
Next example shows running help file and searching for anything that has "users" in the script name.
19+
20+
![alt text](screenshots/pic2.png "Sample run of help.sql file looking for users in script name")
21+
22+
Next example shows running help file and searching for anything that has "trend" in the script name.
23+
24+
![alt text](screenshots/pic4.png "Sample run of help.sql file looking for trend in script name")
25+
26+
Next example shows running help file but we hit enter(no input) and that will spit out all the script names (300+)
27+
28+
![alt text](screenshots/pic3.png "Sample run of help.sql file with no input")
29+
30+
Please note that the help.sql file is not being updated automatically, if we were to add a new script to this repo we will have to manually go in and update the help.sql file to put in the script name, description and if any input is required or not.

screenshots/pic1.png

110 KB
Loading

screenshots/pic2.png

61.3 KB
Loading

screenshots/pic3.png

92.3 KB
Loading

screenshots/pic4.png

48.2 KB
Loading

0 commit comments

Comments
 (0)