Saturday, September 25, 2010

MIITDocID-904: How to check the root blocker (blocking session) and kill it?

Document can be found here.


How to display the output of the query vertically?

Create a procedure called Print_Table as sys

It uses authid_current user so you can install it ONCE per database and many people can use it (with roles and all intact):

Procedure and display instructions are here.

Google Key words: "Tom Kyte Print_Table"


How to check the total “Used” and “Free” database space?

Here is a script to check the total "Used" and "Free" space in a database.


Thursday, September 23, 2010

How to subscribe to free monthly edition of Oracle Magazine? --Moid

To subscribe Oracle Magazine, go here and select "Oracle Magazine" and follow the instructions. Or you can go directly to the subscription page by clicking here.


Monday, September 20, 2010

Find the last recovery time/date of the Oracle database when "resetlogs" option was used to open the database (or when incarnation took place)?


Have you ever been asked when was the database restored/reopened (with resetlog options)? It is a simple thing but sometimes a time consuming task especially if you are not very familiar with Oracle DBA dictionary or if you are a Jr. DBAs. Well, the answer can be found here. Hope this comes handy to someone in need.



Last recovery date
Last restore date
Last recovery time
last restore time

Sunday, September 19, 2010

Friday, September 10, 2010

How to get the client's machine name and their IP Address in Oracle 10g?


I was recently asked to spool out the client’s machine, their IP addresses and the service_name they are using to connect to RAC DB into a text file. I came up with the following queryand it worked like a charm. Although I tested it on a non-RAC db server, I have no doubt it will work on any RAC cluster.