-
Hi everybody !
Does someone know the difference between v$session.username and v$session.schemaname ?
Thanks a lot in advance ...
-
Here the schemaname=schema user name
username= oracle username and both should be the same.
regards
anandkl
anandkl
-
username is the one who runs the query, schemaname is schema which the queries are run against to
for example
I am user SCOTT, when I logon I can do
alter session set current_schema=FORD;
Code:
SQL> select username, schemaname from v$session;
USERNAME SCHEMANAME
------------------------------ ------------------------------
SYS
SYS
SYS
SYS
SYS
SYS
SYS
SYS
SCOTT FORD
Scott has table emp with 14 rows, Ford has empty table emp, now if I query emp as SCOTT but under schema FORD I will be querying FORDĀ“s emp table and not SCOTTs
-
It should be same except for background processes. For BG processes username is usually NULL and schemaname is SYS.
Sanjay
-
Originally posted by SANJAY_G
It should be same except for background processes. For BG processes username is usually NULL and schemaname is SYS.
Sanjay
Hey, Sanjay pls do read the msg clearly before rasing your doubt again.. That was an excellent reply from Pando which clearly says the difference between username and shcema name in v$session. Read that message once again..
-
Originally posted by nagarjuna
Hey, Sanjay pls do read the msg clearly before rasing your doubt again.. That was an excellent reply from Pando
Hey, nagarjuna pls note the time when pando's and Sanjay's messages were posted. You'll note that it is very likely that pando's reply was not published yet when Sanjay started writing down his comment. So there is no need to be harsh on him, simmilar things have happend to many of us....
Jurij Modic
ASCII a stupid question, get a stupid ANSI
24 hours in a day .... 24 beer in a case .... coincidence?
-
Thanks jmodic.
nagarjuna, I hope that clears your doubt.
Sanjay
-
Originally posted by SANJAY_G
Thanks jmodic.
nagarjuna, I hope that clears your doubt.
Sanjay
oh.. I am very very sorry Mr. Sanjay. It was my mistake. Since, I am new to this forum (registered 8 hrs back), I didnt know abt this timing problem and flow of the forum. I am sorry once again.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|