Home » SQL & PL/SQL » SQL & PL/SQL » getting oracle sql information from java application
getting oracle sql information from java application [message #262700] Tue, 28 August 2007 01:42 Go to next message
gurumurthy4
Messages: 17
Registered: August 2007
Junior Member
I want the metrics,execution plan of a sql statement(which is being sent to Oracle using jdbc) to be shown in the java application itself... Can anyone suggest a way to do this? probably finding sql_id from the java application.....
Re: getting oracle sql information from java application [message #262710 is a reply to message #262700] Tue, 28 August 2007 02:09 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
The development plan is:
- get the sql_id for your session
select sql_id from v$session where sid=sys_context('userenv','sid');

- use dbms_xplan.display function to get the execution plan
- add code to display it in your application

Regards
Michel

[Updated on: Tue, 28 August 2007 02:09]

Report message to a moderator

Re: getting oracle sql information from java application [message #262888 is a reply to message #262710] Tue, 28 August 2007 07:48 Go to previous message
gurumurthy4
Messages: 17
Registered: August 2007
Junior Member
i got many useful information from that....thank u very much
Previous Topic: SQL Server to Oracle
Next Topic: Button Problem PL/SQL
Goto Forum:
  


Current Time: Sat Dec 03 16:13:08 CST 2016

Total time taken to generate the page: 0.08111 seconds