PL/SQL :: How To Select Current User Name Who Is Logged In
Jun 19, 2012I'm using Oracle 10g..From a database procedure, how to select the current user name who is logged in
View 7 RepliesI'm using Oracle 10g..From a database procedure, how to select the current user name who is logged in
View 7 RepliesI want to perform something like -
Conn xyz/passwordxyz
grant create procedure to 'xyz';
I want to give permissions to my current user 'xyz' , I am able to give permissions to user using system user but Is there any way to grant permissions to user 'xyz' while I am using 'xyz' user.
I need query to retrive the default tablespace of the current user, when the user is not a dba, i.e. user doesn't have access to dba_users table.
View 2 Replies View Relatedquery to find the current user accessing the database
View 5 Replies View RelatedHow can i get the Current user log in on my system using global variable.
View 6 Replies View RelatedI am having a pipeline function that is called from Java interface.The function is suppose to return a list of events.If it takes too long the customer might cancel it.
I would like to catch in a log table all the information of the input param when the request is canceled.I tried to log every time the sqlcode is -1013, if I dbms_output something then it works, but if i try to call a procedure to do logging, it does not work, or if i try to insert directly in a log table also is not working.
Is it possible to catch(log) this kind of exception.
I am trying to upgrade 10.2.0.4 DB to 11.2.0.3 using DBUA.10g oracle is owned by user ora10gr4 and 11g oracle is owned by user ora11203.I started DBUA from 11g/bin path and while selecting DB i want to upgrade I am getting following error.
Oracle home owner check failed:-PRKH-1014.Current user "ora11203" is not the owner user "ora10gr4" of oracle home "/oracle/ora10gr4"..I cannot give the ownership of both oracle home for same user because of project criteria.
I am experimenting with the 4.2 version of Apex at URL.....
I have created a tabular form (based on a view with an instead of trigger) and have restricted this form to "Update only" mode. Whenever I modify a field value and submit the change I get the error "Current version of data in database has changed since user initiated update process".
In Oracle 11g XE edition, I'm trying to alter a sys owned table by logging as SYS user itself, but still I'm receiving this ORA error code. ORA-12988: cannot drop column from table owned by SYS error
View 5 Replies View RelatedI have an urgent requirement to kill an existing session if a new session starts for the same user. I have been reading lot of blogs and posts on the above topic, but could clearly tell me how to do it.
I thought of putting a process in 101 page when login button is pressed to catch this and kill the old session.
How to find the number of users logged, in a database level(Oracle), b'coz generally in OS level (Linux) , the command will be '$ users',
View 4 Replies View RelatedI just shutdown the database and it seems to take a while, don't know if it's stuck or just takes awhile. I try to restart it in another session and get this error:
'ORA-01012: not logged on'
1) Shutdown
SQL> connect sys/Welcome1 as sysdba
Connected.
SQL> shutdown normal
_
2) So I try to restart it as sysdba on another session and get this error
Connected to an idle instance.
SQL> startup
ORA-01012: not logged on
I have one question on MVIEWS.....
Where the logs will be logged for all the materialized views transactions (I mean a particular table)?
Is there any Data Dictionary Table were i can find this .
What is the difference between the following . In my schema all are giving the same results with some different format
SQL> SELECT sysdate , current_date , current_timestamp , localtimestamp from dual;
SYSDATE CURRENT_DATE CURRENT_TIMESTAMP LOCALTIMESTAMP
----------- ------------ ------------------------------------------------- -------------------------------------------------
5/30/2012 8 5/30/2012 8: 30-MAY-12 08.27.22.037703 AM -04:00 30-MAY-12 08.27.22.037703 AM
I need to verify if the current date is grater than the 15th of the current month. If its grater than the 15th of the current month i need to do an action or if else its lesser than 15th of the current month i need to do an other operation.
View 5 Replies View Relatedcreate an ASM (Automatic Storage Management) instance using dbca. At first try I mistakenly skipped the part where I click on ASM Parameters to add /dev/raw/raw* as my asm_diskstring so it created an ASM instance. When I get to the next page ASM Disk Groups, I selected Create New and I did not have the desired display, because of the step I missed.
I went back to do some cleaning up as follows:
1) Edit the oratab file to remove the ASM entry
2) backed up these files by renaming to old-<filename>
old-ab_+ASM.dat
old-hc_+ASM.dat
old-lk+ASM
old-orapw+ASM
old-spfile2+ASM.ora
3) killed the following processes (kill -9):
oracle 1590 1 0 22:52 ? 00:00:00 asm_pmon_+ASM
oracle 1592 1 0 22:52 ? 00:00:00 asm_psp0_+ASM
oracle 1594 1 0 22:52 ? 00:00:00 asm_mman_+ASM
oracle 1596 1 0 22:52 ? 00:00:00 asm_dbw0_+ASM
oracle 1598 1 0 22:52 ? 00:00:00 asm_lgwr_+ASM
[code]....
4) Run the following as root:
/u01/app/oracle/product/10.2.0/db_1/bin/localconfig delete
5) Restarted the database
Now when I try to go through the steps to create an ASM instance, at the point after I enter my ASM Parameters, I get the following prompt:
"DBCA will now create and start the ASM instance. After the ASM instance is started you can create the diskgroups to be used as storage for your database."
I click OK. Then I get the error message:
ORA-01012 not logged on
i have created form. one field is there "Payment_terms" at line level. for that i created LOV containing 3 fixed Payment terms. my requirement is that Avoid the user to select twice the same value from LOV.
View 8 Replies View RelatedI have a procedure in my schema. I have created a sys context name xyz for passing the date in that i am passing the sysdate to that context which is used in a view.i have used/called that procedure in form.
My problem is that when i am giving Grant select any dictionary to the user then form is compiled otherwise form is giving error procedure name must be declared. But for security reasons i don't to give select any dictionary to that user.
I have granted select privs on below tables to an exisiting user.grant select on WEB.ALMSTAT to nms...I would like to view the privs that i have granted to nms user?
*"In production, nms user will need the ability to read the following tables:*
*WEB.ALMSTAT*
*NET.ASSET*
*NET.LOCATIONNAME"*
How to get all the name of tables that a user can select, insert, update or delete?
View 2 Replies View RelatedI'm new to the sqlplus,
User ID Failed_timestamp
----------------------------------
userA 20100801 11:22:33
userB 20100802 11:22:33
userA 20100802 12:22:44
userA 20100803 13:34:55
userC 20100803 20:21:23
userB 20100804 16:34:56
I wanna to get the last failed time from each user. what is the select statement?
my expected result will be:
userA 20100803 13:34:55
userB 20100804 16:34:56
userC 20100803 20:21:23
how can i enable user to select and save any document into oracle database and later on choose to retrieve and display it.it should be like windows file open save.
View 2 Replies View RelatedI have a requirement while A4 printing..When printing each time user have to select file -> page setup -> size(A4)..THEN printing format become A4 Size. How to achieve this one without user have to go on setting.
View 1 Replies View RelatedThere is a requirement in my database that I want to restrict the user from directly running queries on database from third party tools such as pl/sql developer and toad.
There is a utility in SQL product_user_profile through which this can be done but it is only restricted if you run the query through sql plus. If I want to restrict and (give suppose select,insert) to a user for directly running queries through PL/SQL.
I created an externally authenticated user in database. And can login without password with below syntax.
SQL> connect / @TESTDB
Connected.
SQL> show user;
USER is "SCOTT"
This scott user has a proxy permission to another DBuser PROXY_USER. Previously I used to login using below syntax.
connect scott[proxy_user]/password_for_scott@TESTDB
So now, what syntax should be used for this "ExternallY Authenticated" user to login as a proxy user?
how can i assign permissions to one user to add,delete,edit data and other user should be able to perform all functions or selected functions
View 12 Replies View RelatedI would like to know if 'user creation definition' is exported in user mode export if export is done with DBA role..If it is Not, does it mean we always need to precreate the user before we import the dump created using 'user mode export'?
View 2 Replies View RelatedWe are trying to implement the following security to our database.
As of now, the access rights are same for all the windows users logging into the Oracle application with the same Oracle user Id.
But now, we want to improve our security by granting different levels of rights to the users based on their Network Id even though they use the same Oracle User Id to log into the application.
We are not looking for the users to be identified externally.
(CREATE USER "OPS$ORACLE-BASE.COMTIM_HALL" IDENTIFIED EXTERNALLY;
GRANT CONNECT TO "OPS$ORACLE-BASE.COMTIM_HALL";
)
- we have user id parameter.can we update the parameter(:parameter.p_userid) before firing "WHEN NEW FORM INSTANCE TRIGGER"(when new form instance trigger contain code for tree node), for login another canvas as per user rights?
- i have created a login form in one canvas.
- also tree node Hierarchy form created on another canvas. now we want to login through login screen, after login only those forms should show in tree Hierarchy which users have rights. for this purpose we want to pass the parameter of userid before connecting to tree node form through the following query
SELECT COUNT (*)
INTO v_count
FROM usersinfo
WHERE usersname = :USERBLOCK.usernames AND passwords = :USERBLOCK.passwords ;
[code]...
Every thing is working but when we click on button in login form at that time parameter.p_userid will return null. because above code is define on button click in login screen, i cannot understand where i need to define the above code .
User session has expired. I have to enable user without changing the password of the user.
View 1 Replies View Related