Solved

How to get the web page name in v$session table in Oracle database

Posted on 2010-08-30
2
426 Views
Last Modified: 2012-05-10


We have asp.net web application hosted on IIS (windows) and connecting to Oracle database (10g).

When I query the v$session table in the database,  all I see the program name as "w3wp.exe"
coming from the IIS (web server) host machine.

Now its hard to diagnose as which session in the database is referring to which web page in the web application.

If I have 10 web pages open in my web application connecting to Oracle database, now if I wanted to get there
session info, when I browse the v$session all it shows me is "w3wp.exe" .

Now is there a way to get the web page name in the v$session.

( may be it needs some changes to code in the asp.net web application , change in configuring IIS web server as well ).

Let me know
0
Comment
Question by:OCUBE
2 Comments
 
LVL 76

Accepted Solution

by:
slightwv (䄆 Netminder) earned 500 total points
ID: 33559837
I've never used this but check out: DBMS_APPLICATION_INFO.SET_MODULE

http://www.experts-exchange.com/Database/Oracle/Q_26431656.html

The way I've done this in the past is add comments to the SQL in the .Net code.

VB stub:
sqlStr = "select /* " & scriptNameVariable & " */ column from table"

Then you can look in v$sqlarea to see the text being executed.
0
 

Author Closing Comment

by:OCUBE
ID: 33578657

Thanks
0

Featured Post

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Checking the Alert Log in AWS RDS Oracle can be a pain through their user interface.  I made a script to download the Alert Log, look for errors, and email me the trace files.  In this article I'll describe what I did and share my script.
As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
Via a live example show how to connect to RMAN, make basic configuration settings changes and then take a backup of a demo database
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question