V$session and v$sqlarea
Hi All,
How can i join the v$session and v$sqlarea? I am trying to find out who has executed the sql statement or still executing the statement. I think without joining with v$session its not possible.
Is there a way to get this information?
And I am using Oracle 10g.
Edited by: Ratna Bikram on Sep 25, 2010 11:45 PM
Ratna Bikram wrote:
Hi All,
How can i join the v$session and v$sqlarea? I am trying to find out who has executed the sql statement or still executing the statement. I think without joining with v$session its not possible.
Is there a way to get this information?
And I am using Oracle 10g.
Edited by: Ratna Bikram on Sep 25, 2010 11:45 PMhttp://download.oracle.com/docs/cd/B19306_01/server.102/b14237/dynviews_2088.htm#REFRN30223
SQL_ADDRESS RAW(4 | 8) Used with SQL_HASH_VALUE to identify the SQL statement that is currently being executed
SQL_HASH_VALUE NUMBER Used with SQL_ADDRESS to identify the SQL statement that is currently being executed
SQL_ID VARCHAR2(13) SQL identifier of the SQL statement that is currently being executed
SQL_CHILD_NUMBER NUMBER Child number of the SQL statement that is currently being executedFrom V$SESSION will map into the column in V$SQLAREA. There they will lose the SQL_ prefix (so HASH_VALUE and ADDRESS), but SQL_ID stays the same.
Similar Messages
-
V$session and v$sqlarea is interpreting in different way
I am using redhad linux 5 version. The db version is oracle11g.
I am trying to run the below shell script on the linux box
export ORACLE_SID=chf01
export ORACLE_HOME=/ora/app/oracle/product/11.1.0/db_1
export WORKDIR=/ora/app/oracle/admin/chf01/scripts
cd $WORKDIR
$ORACLE_HOME/bin/sqlplus scott/tiger@ch01 << EOF
spool sqlcapture.log
INSERT INTO scott.T_SQL_CAPTURE
SELECT MACHINE,
SQL_FULLTEXT
FROM
v$session a,
v$sqlarea b
where
((a.sql_address = b.address
and a.sql_hash_value = b.hash_value )
or ( a.prev_sql_addr = b.address
and a.prev_hash_value = b.hash_value))
commit;
spool off
exit
EOF
ERROR=`grep 'ORA-' sqlcapture.log | wc -l`
if [ "$ERROR" -gt 0 ]
then
cat sqlcapture.log|mailx -s "sqlcapture is failed" \ [email protected]
else
cat sqlcapture.log|mailx -s "sqlcapture is successful" \ [email protected]
fi
exit
here is the spool file content. v$session is interpreted as v a and v$sqlarea is interpreted as v b.
How can i fix this?
SQL> INSERT INTO scott.T_SQL_CAPTURE
2 SELECT MACHINE,
3 SQL_FULLTEXT
4 FROM
5 v a,
6 v b
7 where
8 ((a.sql_address = b.address
9 and a.sql_hash_value = b.hash_value ) 10 or ( a.prev_sql_addr = b.address
11 and a.prev_hash_value = b.hash_value))
13 ;
v b
ERROR at line 6:
ORA-00942: table or view does not exist
SQL> commit;
Commit complete.
SQL> spool offBecause *$* is interpreted by Linux shell. So you need to escape it. I used to escape all $ with \$ but someone in another thread posted a lovely trick. Use this:
$ORACLE_HOME/bin/sqlplus scott/tiger@ch01 << \EOF
. -
Clarification in V$SQL and V$sqlarea
Hi Gurus, I have a clarification in V$SQL and V$sqlarea. Is it possible to get the entire set of SQL commands that are executed or run for particular session irrespective of the number of commands that are executed during the session. And can this result be got in a text file.
thanks in advance.Hello,
with execute dbms_system.set_sql_trace_in_session(session_id, serial_id, {True | False}) you can activate SQL tracing for a specific session. SQL Trace will generate a trace file in udump. With TKPROF you can format the output.
If you want to trace your session: ALTER SESSION SET SQL_TRACE = TRUE
regards,
juergen_klinsmann -
I have to manually close the extra windows and restore the tabs from the previous session, and reopen the sidebar. In disgust I uninstalled Firefox 4 and reinstalled 3.6. Everything works fine in 3.6. Looks to me like Firefox 4 has many major bugs and is not yet ready for prime time. I'll stay with 3.6 for now.
This can be a problem with the files [http://kb.mozillazine.org/sessionstore.js sessionstore.js] and sessionstore.bak in the [http://kb.mozillazine.org/Profile_folder_-_Firefox Profile Folder]
Delete [http://kb.mozillazine.org/sessionstore.js sessionstore.js] and sessionstore.bak in the [http://kb.mozillazine.org/Profile_folder_-_Firefox Profile Folder]
* Help > Troubleshooting Information > Profile Directory: Open Containing Folder
If you see files sessionstore-##.js with a number in the left part of the name like sessionstore-1.js then delete those as well.<br />
You will have to redo App Tabs and Tab Groups after deleting sessionstore.js.
See:
* http://kb.mozillazine.org/Session_Restore -
Difference between connection, session and process
Hi all,
Can anyone please update me on the difference between connection,session and process.
Thanks in advance,
- SriI got this useful note by googled in net. It describes session,connection,process gracefully.
A connection is a physical circuit between you and the database.A connection
might be one of many types -- most popular begin DEDICATED server and SHARED
server. Zero, one or more sessions may be established over a given connection
to the database as show above with sqlplus. A process will be used by a session
to execute statements. Sometimes there is a one to one relationship between
CONNECTION->SESSION->PROCESS (eg: a normal dedicated server connection).
Sometimes there is a one to many from connection to sessions (eg: like
autotrace, one connection, two sessions, one process). A process does not have
to be dedicated to a specific connection or session however, for example when
using shared server (MTS), your SESSION will grab a process from a pool of
processes in order to execute a statement. When the call is over, that process
is released back to the pool of processes. -
Report in new page does not know of session and presentation variables
I have a question about GOURL.
I am using GOURL as a column function in one report (report A), so that when i click on that column it takes me to another report(report B) that open in new popup window.
the first report (A) also uses some session and presentation variables, which is also used by Report B as filters. I am curious that if I add these filters which are using variables to report B, why can't report B get the value of these, (it just errors out ) because it didn't found any value to those variables in the filter.
Becuase I am ending up with passing all these variables in GOURL and setting them as 'isprompted'.
Does this report (B) knows nothing else than what it finds in GOURL?
thanksIn a nutshell, if u use gourl then its parameters will be only using in navigated report. This is functionality
-
Safari doesn't "Reopen All Windows From Last Session" and links from Mail
After a crash I found myself trying to "Reopen All Windows From Last Session", then I found that if I click a link from Mail it does not open it ... as well from any other application. It's like only workin' within itself and can't interact with any other application. Plus I used a lot "Reopen All Windows From Last Session" and now it doesn't work
Same thing just happened to me. Reinstalling Saferi did not help.
-
Lion 10.7.2 On both mac book pro and iMac, both with Lion 10.7.2, obtain repeated iCal event notifications from calendar or address book. Cannot turn these off. They repeat several times per session and every time computer is used. How to diagnose this?
First, uninstall "SuperTV" (whatever that is) according to the developer's instructions. It isn't working and it's filling the log with noise.
If you have more than one user account, these instructions must be carried out as an administrator.
Launch the Console application.
Step 1
Make sure the title of the Console window is All Messages. If it isn't, select All Messages from the SYSTEM LOG QUERIES menu on the left.
Enter "BOOT_TIME" (without the quotes) in the search box. Note the timestamps of those log messages, which refer to the times when the system was booted. Now clear the search box and scroll back in the log to the last boot time when you had the problem. Post the messages logged before the boot, while the system was unresponsive or was failing to shut down. Please include the BOOT_TIME message at the end of the log extract.
Post the log text, please, not a screenshot. If there are runs of repeated messages, post only one example of each. Don’t post many repetitions of the same message. When posting a log extract, be selective. In most cases, a few dozen lines are more than enough.
PLEASE DO NOT INDISCRIMINATELY DUMP THOUSANDS OF LINES FROM THE LOG INTO A MESSAGE. If you do that, I will not respond.
Important: Some private information, such as your name, may appear in the log. Edit it out by search-and-replace in a text editor before posting.
Step 2
Still in Console, look under System Diagnostic Reports for crash or panic logs, and post the most recent one, if any. In the interest of privacy, I suggest you edit out the “Anonymous UUID,” a long string of letters, numbers, and dashes in the header of the report, if present (it may not be.) Please don’t post shutdownStall, spin, or hang logs — they're very long and not helpful. -
Question about BC4J data tags, Oracle sessions and Locking!
Hi ,
I have seen numerous examples of JSPs using data tags and in all the examples the data tag for the application module has the "username" and "password" harcoded in it.
My questions are:
1) For a stateful application should we be including the username and password in every JSP page. I personally believe that we should not.
2) If we have a username and password in every JSP page will it not start a new ORACLE user session and if so will it not cause locking problems?
3) If we don't hard code the username and password in every JSP page, will it reuse the same ORACLE session ?
4) How do we avoid locking problems when we use data tags?
5)I can understand the inclusion of username and password in every JSP page if it is a stateless application but again Is there a way we can avoid hardcoding the username and password in every single page?
I would appreciate if some one can let me know if any of my assumptions are incorrect.
JDeveloper Team/Juan any advice?The username and password are optional. They can be provided via the connections.properties file. The multple entries for username and password don't mean that separate connection are made. The first time the ApplicationModule tag is encountered, your application instance is created. If you are running in reserved mode (look at your releasePageResources tag) the application instance is kept until your Http session times out. If you are running in Stateful or Stateless mode, you application instance is returned to the application pool and retrieved the next time you need an instance. Please refer to the application pool documentation and to the source in oracle\jbo\common\ampool provided in jbohtmlsrc.zip.
-
I am trying to sign in to attend a session and it says 'Invalid user or password. Please try again.' I have reset my password and it still doesn't work. I created a new AdobeID and it still doesn't work. I need to attend this training. How can I get in?
Sorry to hear about this problem. What site are you trying to log in on? Is it a Mozilla site? Usually you don't need to register or sign in to a Mozilla site to use Firefox. Usually you can just go straight to where you want to go.
-
I don't like anything opening automatically when I start Firefox, so before Firefox 4 I set Firefox to open a blank page when it starts. I still had set a page I visit frequently as my home page, so I could get to that page quickly by pressing the home button. If I needed to close Firefox it was nice and easy to have the option to save my session and close (I've already searched and read another post and answer on how to restore this feature in about:config). I understand that Firefox 4 always saves your session and you can restore it from the history menu, but then I would have to remember if I had anything open and click menu/History/Restore Previous Session.
Now in Firefox 4 I have left the home page set to about:home so if I had tabs open when I closed it I would see the Restore Previous Session "button" the next time I start it. However, when I close all windows and tabs before exiting Firefox, the Restore Previous Session "button" will be sometimes be there. If I click it, it will open a random tab or window that I visited the previous day, which was NOT the last tab/window that I had open.
If I do have tabs open when I close it, it does correctly re-open them when using the Restore Previous Session button, it only does this if I do a clean exit (close all tabs/windows before close).
I tried deleting the sessionstore.js and sessionstore.bak files from my Firefox appdata directory (there were no other sessionstore.* files). This is a clean install of Firefox 4, I didn't install on top of Firefox 3.6.xx. I uninstalled Firefox 3.6.xx before installing and made sure to delete any leftover files in my appdata, programdata and program files directories.I thought about that before and tried it, and it doesn't seem to make a difference. I did it just now, I opened a blank tab and closed everything else, waited a minute then closed Firefox. I waited another minute and launched Firefox. The Restore Previous Session box was there on about:home. I clicked it and it opened a new window with about:home in it.
-
Web session and authentification session pb with wl6.0
Hi,
I am evaluating weblogic 6.0 on windows 2000.
I have a little web application, with some URL (html, servlet...), I want to protect.
So I defined a <security-constraint> element in my web.xml
file, and I binded the logical roles with real participant in
weblogic.xml
It works very well at startup. I launch a browser, request a protected URL and the
authentification window popup. I enter valid info and I can access my URL.
Perfect.
Now I want to give the possibility to my user to terminate a session, to disconmect,
so I had a button, (disconnect) which invoque a servlet which get the current session
and invalidate it.
I checked, the session is destroyed and a new one is defined (new ID, new counter...),
but my user are still connected. It means that if I want to acces a protected URL,
I still can do it.
more strange. In both a secured and unsecured page I print the User Principal. When
I connect, the two pages print the same and right value.
But if I disconnect, the unsecured page print null(no connection for this session)
and the secured page print the principal I used to connect in the previous message.
I know this message is a little bit long, but I tried to give the cleares context.
Has anyone ancountered that kind of problem? Is there a solution.
I pass the test with netscape 4.76, netscape 6.01, Internet Explorer 5.50. I got
the same behavior each time...
Thanks
NicolasIf you use a Form to authenticate then the browser is unaware of the
username and password. The PetStore demonstrates how it's done in
..\samples\petStore\source\com\bea\estore\util\WLSecurityAdapter.java
"Nicolas GANDRIAU" <[email protected]> wrote in message
news:[email protected]...
>
Hi John,
thank you for your answer. It confirmed my first guess, that the
browser keep the secret info and send them back to the server.
The server does not make any attachment with the current session.
But you talk about a "ServletAuthentication" example which presents theway to bind
the login info in the session. I have not found this servlet, in weblogic6.0 distribution
or J2EE API.
Can you give me the exact reference of this servlet.
Thank you for your help.
Nicolas
"John Lindwall" <[email protected]> wrote:
Nicolas,
It is my understanding that the authentication information for this
scenario
(ie HTTP BASIC authentication) is not contained in the session -- it is
maintained by the browser and resent with every request. That is why
invalidating the session makes no difference. If you have a HTTPsnooping
utility you will see the "Authorization" information (albeit encodedusing
BASE64) present in the requests from your browser to the server.
FYI: I've noticed that by using the ServletAuthentication class tomanually
perform authentication, it DOES in fact store the authentication info in
the
session. There is a "done()" method in this class which removes thisinfo
from the session (ie performs a logout).
If this link reproduces properly, check it out -- it's a good simple
explanation of what's going on:
http://www.support.lotus.com/sims2.nsf/852561c1006719a98525614100588964/877
a
0ac029a78f8a8525645f0069a34d?OpenDocument
For tons of detail on BASIC authentication see
ftp://ftp.isi.edu/in-notes/rfc2617.txt
John
Nicolas GANDRIAU <[email protected]> wrote in message
news:[email protected]...
Hi,
I am evaluating weblogic 6.0 on windows 2000.
I have a little web application, with some URL (html, servlet...), I
want
to protect.
So I defined a <security-constraint> element in my web.xml
file, and I binded the logical roles with real participant in
weblogic.xml
It works very well at startup. I launch a browser, request a protectedURL
and the
authentification window popup. I enter valid info and I can access myURL.
Perfect.
Now I want to give the possibility to my user to terminate a session,to
disconmect,
so I had a button, (disconnect) which invoque a servlet which get thecurrent session
and invalidate it.
I checked, the session is destroyed and a new one is defined (new ID,new
counter...),
but my user are still connected. It means that if I want to acces aprotected URL,
I still can do it.
more strange. In both a secured and unsecured page I print the UserPrincipal. When
I connect, the two pages print the same and right value.
But if I disconnect, the unsecured page print null(no connection for
this
session)
and the secured page print the principal I used to connect in the
previous
message.
I know this message is a little bit long, but I tried to give the
cleares
context.
Has anyone ancountered that kind of problem? Is there a solution.
I pass the test with netscape 4.76, netscape 6.01, Internet Explorer
5.50.
I got
the same behavior each time...
Thanks
Nicolas -
Safari 5.1.7 resumes last session and freezes immediately
Hello,
Upon the start of Safari, it resumes the last session and immediately freezes, showing the spinning rainbow and failing to load pages. None of the toolbar options can be accessed. I can only force quit. Restarting the computed accomplishes nothing.
I am running Mac OS 10.7.4 with Safari 5.1.7
Thanks.Open System Preferences > General
Deselect: Restore windows when quitting and re-opening apps
Now restart your Mac, launch Safari.
From the Safari menu bar top of your screen, click Safari > Empty Cache
See if that made a difference... -
Log file in session and call transaction methods
Hi Experts,
How to see log file in session and call transaction methods?hi
If its a session then goto SM35, select ur session and then u can see log button over there at the top... that will give the log
If its a call transaction then in ur program u need to declare internal table IT_MSGS like this
DATA: IT_MSGS LIKE BDCMSGCOLL OCCURS 0 WITH HEADER LINE.
LOOP AT IT_SALES.
PERFORM POPULATE_BDC.
CALL TRANSACTION 'VA01' USING IT_BDCDATA
MODE MODE
UPDATE UPDATE
MESSAGES INTO IT_MSGS.
IF NOT IT_MSGS[] IS INITIAL.
LOOP AT IT_MSGS.
CALL FUNCTION 'FORMAT_MESSAGE'
EXPORTING
ID = IT_MSGS-MSGID
LANG = 'EN'
NO = IT_MSGS-MSGNR
V1 = IT_MSGS-MSGV1
V2 = IT_MSGS-MSGV2
V3 = IT_MSGS-MSGV3
V4 = IT_MSGS-MSGV4
IMPORTING
MSG = V_MSG
EXCEPTIONS
NOT_FOUND = 1
OTHERS = 2.
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
WRITE:/ V_MSG.
ENDLOOP.
ENDIF.
ENDLOOP.
This will create a log for you, dont forget to award points if found helpful -
After a session has been invalidated using Session.invalidate() method, the next time a user logs in to the application within the same browser session and the servlet (as JSP) attempts to access a session variable; the session variable is no longer available. After printing the session id, JSession ID is appended to the session id which results in lost session after another page is loaded. Once again, this only happens after the session has been invalidated as mentioned before.
Hi Anand,
Invalidating a session effectively destroys all
variables bound to the session.
Regards,
Slava Imeshev
"Anand" <[email protected]> wrote in message
news:[email protected]..
> After a session has been invalidated using Session.invalidate() method,
the next time a user logs in to the application within the same browser
session and the servlet (as JSP) attempts to access a session variable; the
session variable is no longer available. After printing the session id,
JSession ID is appended to the session id which results in lost session
after another page is loaded. Once again, this only happens after the
session has been invalidated as mentioned before.
Maybe you are looking for
-
Why does Yahoo Search appear when I open a new tab, when Google is my default homepage?
Ever since I upgraded to 4.0, when I open a new tab the yahoo search page appears, but my homepage is www.google.com. I have three tabs open at all times on my main foxfire window and always ask to restore them: Yahoo mail (my account), www.imdb.com,
-
After spending countless hours on a project in Final Cut Express only to discover its poor rendering power, I ultimately decided to try and rebuild my project in FCP X - especially since I could try it for free. At first, FCP X ran fine. After a week
-
Skipping system dump : no dump device configured
Hi all! I am new to Solaris, please understand. I receive the following message "skipping system dump : no dump device configured" and my system reboots. After reboot, the system repeats the initial installation. My IDE config: Primary Master - disab
-
Automatically import new purchases
I have succesfully set up home sharing on my network but do not see the ""Automatically import new purchases" option under advanced settings. Where is this option or is it not implemented yet. I am on the latest version of itunes and can successfully
-
SUDDENLY the image from LR to psd looks different
Never before. Do what please? Nothing changed from the previous conversion. Photo>Edit in >smart object in PS. PhotoPRo space left is psd from LR, right is NEF adjusted in LR Mac OSX.8.2