A fall connected users in Oracle DB

I want to put some users in Oracle DB using sqlplus but I get the error message:

SQL > test DROP USER CASCADE;.
Test of DROP USER CASCADE
*
ERROR on line 1:
ORA-01940: cannot delete a user who is currently logged on

But when I ran under control for connected sessions I get no results:

SQL > select sid, serial # of the v session $ where username = 'test ';

no selected line
Please help me how to remove users from this case.

User names, like all other objects in the database, are case-sensitive when City as strings. Try this variation on your code:

select sid,serial# from v$session where username = 'TEST';
{code}
Cheers, APC                                                                                                                                                                                                                                                                                                                                                                                                                                                

Tags: Database

Similar Questions

  • After changing the orainventory place im unable to connect using the oracle user

    Hello

    IM using oracle 12 c on rhel 6 after correctly installing the software, I changed the location of oravinventory in/data/houses

    / u01/app/Oracle

    After making these changes im is no longer able to connect using the oracle user...

    also I back return changes I had made to the orainventory folder still unable to connect using the oracle user...

    any help on this would be greatly appreciated

    Sadia. wrote:

    Hello

    IM using oracle 12 c on rhel 6 after correctly installing the software, I changed the location of oravinventory in/data/houses

    / u01/app/Oracle

    After making these changes im is no longer able to connect using the oracle user...

    also I back return changes I had made to the orainventory folder still unable to connect using the oracle user...

    any help on this would be greatly appreciated

    Newer versions of oracle have implemented a great new technology to help solve problems, called "error messages."  Unfortunately, I can't find any reference to an error message named 'is no longer able to connect.

    And why you are moving your site from inventory?  When you have installed oracle, he put the inventory where he wanted.  There is no reason to try to change or replace.

  • howmany oracle user to connect with the oracle server.

    Hi all

    howmany oracle user to connect with the oracle server.
    I want to search for above sentence.

    Select the user name, count (*) from v$ session group by user name;

  • connection to the oracle application express using java and jdbc

    Hello!

    I am trying to build a java application using jbcd to connect to my Oracle Application Express DB but unable to connect actually using the following syntax:

    Private final static String DB = "myworkspacename";

    Private final static String RUTA public = "@apex.oracle.com:1521";

    private public static final String URL = "jdbc: Slim:" + RUTA + "/" + DB;

    private static final String DRIVER = "oracle.jdbc.OracleDriver";

    a USER private final static string = " " [email protected] "; "

    private final static String PASS = "MonMotpasse";

    and then I start the connection via:

    CONEX = DriverManager.getConnection(URL,USER,PASS);

    but finally I get the following error:

    IO error: the network adapter could not establish the connection

    any ideas on what goes wrong will be appreciated...

    Simple answer... YOU can't connect externally to the hosted instance of Oracle with a jdbc connection or sql developer/Toad.  Not allowed...

    If you need this capability, I would suggest downloading of Oracle 11 g XE and building you own database...

    Thank you

    Tony Miller
    Software LuvMuffin
    Ruckersville, WILL

  • problem connecting to the oracle database.

    A user cannot connect to the Oracle server. What will be the problem and the solution to the problem?

    When you post here you must give us: error codes, logs, DB versions, SO it's 32-bit is 64-bit?

    Give us more details about your problem and maybe I can help you.

  • How to get more information about the users in oracle 11g

    Hi all

    I need to know more information on users in oracle 11g.

    1. how to check when user times last connection to the database.
    2. If the user account is blocking why it is blocked? If it is locked trying Loing with wrong password how to check how many times he tried with wrong password... and other reasons also
    3 reaction strives to select user expire date is to show the value empty... we can check expire date by querys or we need to check the profile?
    4. how to check while he was reset his password, the last time.

    Please correct me if am wrong. Thank you

    Concerning

    1. how to check when user times last connection to the database.

    AUDIT

    2. If the user account is blocking why it is blocked? If it is locked trying Loing with wrong password how to check how many times he tried with wrong password... and other reasons also

    Check the profile of this user and attr.

    3 reaction strives to select user expire date is to show the value empty... we can check expire date by querys or we need to check the profile?

    SQL> select EXPIRY_DATE from dba_users ;
    
    EXPIRY_DA
    ---------
    24-SEP-11
    24-SEP-11
    24-SEP-11
    24-SEP-11
    24-SEP-11
    24-SEP-11
    24-SEP-11
    23-MAY-13
    24-SEP-11
    24-SEP-11
    24-SEP-11
    

    check
    EXPIRY_DATE in dba_users is null

    4. how to check while he was reset his password, the last time.

    SELECT SYS PTIME. THE USER$;

  • concurrent users in oracle applications

    How to find the no. of concurrent users in an oracle applications

    Kind regards

    Hafiz

    Hafiz says:
    How to find the no. of concurrent users in an oracle applications

    Kind regards

    Hafiz

    Please see the old subjects to the scripts/docs get the list of users connected - https://forums.oracle.com/forums/search.jspa?threadID=&q=users+AND+Connected&objID=c3&dateRange=all&userID=&numResults=15&rankBy=10001

    Thank you
    Hussein

  • Unable to connect to the Oracle 10g transparent VBA code

    Dear all,

    I am unable to connect to the oracle database, use the code for the same below.
    And the name of the server is PRDCCB, my TNSNAMES file. ORA file is placed correctly, and defined environment variable path.
    Fanny created in VBA ADO objects.
    But am not able to connect error is always the driver's SQLSETConnectAttr failed

    Help, please



    Void Ora_Connection()

    Con Dim As ADODB. Connection
    Dim rs As ADODB. Recordset
    Dim query As String
    The con value = New ADODB. Connection
    Set rs = New ADODB. Recordset


    ' - Replace below highlighted the names with the corresponding values

    con. Open ("Driver = {Microsoft ODBC for Oracle};" & _)
    "CCBPRD = DESCRIPTION =" & _
    "(ADDRESS =(PROTOCOL=TCP)"& _
    "(HÔTE = 10.1.3.50) (PORT = 1521))" & _
    "(CONNECT_DATA = (SID = CCBPRD))); UID = Prasad; pwd = prasad23; »)

    ' - Open the above connection string.


    ' - Now connection is open and you can use queries to execute.
    ' - It will be open until you close the connection
    End Sub

    Replace pls

    con.Open ("Driver={Microsoft ODBC for Oracle}; " & _
    "CCBPRD=DESCRIPTION=" & _
    "(ADDRESS=(PROTOCOL=TCP)" & _
    "(HOST= 10.1.3.50)(PORT=1521))" & _
    "(CONNECT_DATA=(SID=CCBPRD))); uid=Prasad; pwd=prasad23;")
    

    with

    con.open ("Provider=MSDAORA;Data Source=CCBPRD;User ID=Prasad; Password=Prasad23;";)
    


    Rgds,

    Ahmer


    N.B.: To win a good reputation on the forums, and if you want that your question will be answered in due time. Kindly adopt a used to score your closed questions as soon as you give the answer. and be courteous to people who tries to help.

  • Connect to the Oracle database - does not connect

    I am new to JAVA and for the first time that I am trying to connect to an Oracle using JAVA data. Well, I get an error when you try to connect to the database. I can see that the error doesn't that make strings passed to make the databases of connection are NULL. Thus, an error (see error below).

    Question
    How is the 'connection' varriable is NULL?
    It seems that the hold 'try' session was not executed. This session is broken?

    ERROR

    The database connection is not found: null
    Database connection before call: null
    Exception in thread "main" java.lang.NullPointerException
    at TestOCIApp.main (TestOCIApp.java:39)


    = JAVA START program =.

    import java.sql. *;
    import java.sql.Connection;
    to import java.sql.DriverManager;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;

    public class TestOCIApp {}

    Public Shared Sub main (string args []) throws ClassNotFoundException,
    SQLException {}

    Fitting out = null;
    try {}
    Load the JDBC driver
    String driverName = "oracle.jdbc.driver.OracleDriver";
    Class.forName (driverName);

    Create a connection to the CCM PROD database
    String serverName = "192.168.2.144";
    String portNumber = "1521;
    String sid = "op01ccdb01";
    String url = "JDBC: thin: @" + serverName + ":" + portNumber + ":" + sid;
    String username = 'user id ';
    String password = "password";
    connection = DriverManager.getConnection (url, username, password);
    System.out.println ("connection value:" + connection);

    } catch (ClassNotFoundException e) {}
    The database driver is not found
    System.out.println ("could not find the connection to database:" + connection);
    } catch (SQLException e) {}
    Could not connect to the database
    System.out.println ("could not connect to the database connection:" + connection);
    }

    System.out.println ("connection to the base before the call:" + connection);
    Statement stmt = connection.createStatement ();
    ResultSet rset = stmt.executeQuery ("select" driver Tester Hello OIC ' |) THE USER: '! ("' result from double ');
    While (rset.next ())
    System.out.println (RSet.GetString (1));
    RSet.Close ();
    stmt. Close();
    Connection.Close;
    }
    }


    = END of JAVA program =.

    The try section runs very well but only partially because you get the exception "ClassNotFoundException", which means that it is impossible to load the Oracle driver class (so it does not reach the line where it says):

    Class.forName(driverName);
    

    You intercept this exception and then simply print a line "could not find the database connection: null". Then you let the code continue, obviously without you still initialize your variables.

    I would recommend rewriting those catch blocks throw new RuntimeException so that the code will not continue any further when an error is detected in the try or don't catch not all of them if you donot want to manage them appropriately.

    As for your problem, you probably have not added the ojdbc14.jar is to your project, and this is why it cannot find the class OracleDriver.

    Finally, try adding {noformat}

    {noformat} around your code when you post code.  It makes it a lot more readable.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    
    
  • map a user process oracle for the process of the BONE?

    Hi all

    When a client connects to the Server DB and oracle user
    process (< SID > oracle) is started in (dedicated solaris
    Server mode), how can I know who is the actual process
    Is this connection?

    for example: sid is db1

    ps - ef | grep oracledb1
    ...
    ...
    0 S 17406 1 0 39 20 oracle? 2159176? 09:50:09? 0:31 oracledb1 (LOCAL = NO)
    0 S 22198 1 0 39 20 oracle? 2158821? 10:18:37? 0:01 oracledb1 (LOCAL = NO)
    0 S 9873 1 0 39 20 oracle? 2158275? 12:14:06? 0:01 oracledb1 (LOCAL = NO)
    ...
    ...

    How will I know which of the oracledb1 belongs to a customer connection?

    Thank you very much!
    Sam

    user8803644 wrote:
    Hi all

    When a client connects to the Server DB and oracle user
    process (oracle) is started in (dedicated solaris
    Server mode), how can I know who is the actual process
    Is this connection?

    for example: sid is db1

    ps - ef | grep oracledb1
    ...
    ...
    0 S 17406 1 0 39 20 oracle? 2159176? 09:50:09? 0:31 oracledb1 (LOCAL = NO)
    0 S 22198 1 0 39 20 oracle? 2158821? 10:18:37? 0:01 oracledb1 (LOCAL = NO)
    0 S 9873 1 0 39 20 oracle? 2158275? 12:14:06? 0:01 oracledb1 (LOCAL = NO)
    ...
    ...

    How will I know which of the oracledb1 belongs to a customer connection?

    Thank you very much!
    Sam

    Do as below

    SQL> connect user1/user1
    Connected.
    SQL> !ps -ef | grep LOCAL
    oracle   32331 26842  0 20:36 ?        00:00:00 oraclev112 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
    bcm      32332 26842  0 20:37 pts/0    00:00:00 /bin/bash -c ps -ef | grep LOCAL
    bcm      32334 32332  0 20:37 pts/0    00:00:00 grep LOCAL
    
    SQL> select
       b.username,
       b.sid,
       b.serial#,
       a.spid
    from
       v$session b,
       v$process a
    where
       b.username = 'USER1'
    and
       a.addr = b.paddr
    /  2    3    4    5    6    7    8    9   10   11   12   13  
    
    USERNAME                     SID    SERIAL# SPID
    ------------------------------ ---------- ---------- ------------------------
    USER1                          146     1288 32331
    
    SQL> 
    

    Handle: user8803644
    Status level: Beginner
    Join date: December 29, 2010
    Messages total: 13
    Total Questions: 5 (5 open)

    Why EACH question still unanswered?

    Published by: sb92075 on February 15, 2012 20:43

  • Do not drop DMSYS user on Oracle 11 upgrade.

    Hello;


    Version Oracle 11.2.0.2
    OS version Red Hat 5 AS U7

    I missed fall DMSYS user on a database and now I display the invalid objects for DMSYS. I dropped DMSYS casacde, but things always show.

    I searched MOS documents but have not found a cleaning paper.

    Can someone point me to the right direction?

    Not having not problem, just want to clean.

    There is a step by step procedure here: http://docs.oracle.com/cd/E11882_01/datamine.112/e16807/upgrade_odm.htm

    After droping DMSYS user with the cascade option make sure you:

    SQL> DELETE FROM sys.exppkgact$ WHERE schema = 'DMSYS';
    SQL> SELECT COUNT(*) FROM dba_synonyms WHERE table_owner = 'DMSYS';
    

    If the result of the select is not zero lines, create and run a SQL script as follows:

    SQL> set head off
    SQL> spool directory_path/drop_dmsys_synonyms.sql
    SQL> SELECT 'Drop public synonym ' ||'"'||SYNONYM_NAME||'";'
                 FROM DBA_SYNONYMS WHERE TABLE_OWNER = 'DMSYS';
    SQL> spool off
    SQL> @directory_path/drop_dmsys_synonyms.sql
    
  • The idea to send a message to all connected users.

    Dears,

    I am developing through oracle forms an idea of sending a message pop up to all connected users.
    Example, I need to inform users to quit smoking in 5 minutes due to a restart of the application server.

    I thought about a timer trigger that will check every 5 seconds or 10 seconds one value in a table somewhere. But I don't want to use the timer associated with forms of oracle triggers.

    Y at - it an idea?

    Please let me know.

    Joe

    Normally, there is a clue when the Java Bean needs a greater than 1.3 JRE, so I guess (but it must be confirmed by a real test) that she will be executed with the JInitiator.

    François

  • DB connection - user SYS with wrong password

    Hi all

    One strange thing I noticed with the SYS user as Oracle 9i (who has never worked on earlier versions), it is that I can connect to SYS as SYSDBA with wrong password user as well! Please guide how to avoid this...
    (I have looked for a solution online but could not find any :())
    SQL> CONN SYS/AAA@TEST AS SYSDBA
    Connected.
    SQL> DISC
    Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    SQL> CONN SYS/BBB@TEST AS SYSDBA
    Connected.
    SQL>
    SQL> DISC
    Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    * 009 *.

    There is nothing wrong, and nothing should be, IMO, prevented.
    When you connect to the server as a user in the Group dba (Unix) or group ora_dba (Windows), you are an advanced user and authentication of the o/s applies to you, and you don't need a password .
    Login as the owner of the software (oracle) all the time, what do many DBA, is a bad idea in any case, you can remove anyufile o/s level.

    Strategies to avoid it:
    -Make sure that your account is not in the groups I mentioned
    or
    -disable authentication of the o/s of editiing sqlnet.ora

    The two procedures are documented.

    Finally, note someone who has root access can move easily.

    -------------------
    Sybrand Bakker
    Senior Oracle DBA

  • Invalid connection for the Oracle 10 g Server

    Hello

    I installed Oracle 10 g server on my pc.

    I checked the Option to use the same user name and password for all accounts and used the password as an administrator

    But when I try to connect as sysdba or sysopera with admin as password it's displaying as connection not valid.

    Please tell me how I can connect to the Oracle database

    User for login names are SYS or SYSTEM. Try to connect as administrator system or admin/sys as sysdba.

    Which tool you use to connect? dbconsole, sqlplus? You should be able to connect with the authentication of the OS "/ as sysdba".

    Published by: Robert Geier on October 13, 2009 14:27

  • How to authenticate the user using oracle user

    Hello
    I do some piece of my apex application login authentication and what I want to do is to let people connect with the user Oracle (schema) and the password also, in the system. I know that we have a dba.users table that contains the usernames and respective encrypted passwords for users of Oracle. But using this table is not the right way for my solution. Is there another way I can authenticate the user if he uses the username/password Oracle (as sys/respective password)?

    Hello:

    You might want to consider 'DAD authentication' for your application as described here

    http://download.Oracle.com/docs/CD/E14373_01/AppDev.32/e11838/sec.htm#CHDJBAIF

    CITY

Maybe you are looking for

  • In the upper right corner squiggley lines

    HelloMac 10.6.8 Firefox 10.0.1 - double configuration screen.There are 3 lines undulate in the upper right corner, but only when the browser is on the 2nd screen (right), they are not there when it is on the main screen (left). I'll post a response t

  • LaserJet P1102: Driver for LaserJet P1102w

    Need help for my LaserJet P1102w operate with Windows 10. Best regards / Tomas

  • How a router via the Telnet command file

    Dear boss I have a few remote cisco router and have telnet access to the router (172.16.1.1, 172.16.2.1...). I want to add a route to the router through a windows batch file. How do I? Please help me with the sample. Thanking you Shahid

  • SPA112 firmware 1.0.1 update 22 to something else...

    When I go in the "Administration" tab, there are only options web change 80 or 443. No options on the left for the firmware, or anywhere else in the GUI. PLEASE HELP ASAP! Scott parks

  • Droid phone problem?

    Droid has a green light that flashes on the top right indicating, message waiting. It has stopped working, how do I turn it back on?