DELETE FROM table - worked or not?

I executed a DELETE FROM statement against a table in my database, and the EM Console reports 8 ranks (which is correct). But when I SELECT * from the table, I get 10 lines (including 2 I wanted to delete).

What I did and how I can fix? I want to only 8 rows

Thanks in advance

If you want to kill a session on the oracle side, you find two things, Sid and serial V$ session.
See here,

session1>select sid,serial# from V$session where username='SCOTT';

       SID    SERIAL#
---------- ----------
       136         32

session1>

And we kill the session to change the KILL session system statement and if you kill a session, the transaction not committed. See here,

C:\WINDOWS>sqlplus scott/tiger

SQL*Plus: Release 10.2.0.1.0 - Production on Thu Sep 11 21:09:30 2008

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options

SQL> delete from emp;

14 rows deleted.

SQL>

And I kill session now and control the data of the other session, see below

session1>select sid,serial# from V$session where username='SCOTT';

       SID    SERIAL#
---------- ----------
       136         36

session1>alter system kill session '136,36' immediate;

System altered.

session1>
SQL> select * from emp;
select * from emp
            *
ERROR at line 1:
ORA-03113: end-of-file on communication channel

SQL> conn scott/tiger;
Connected.
SQL> select * from emp;

     EMPNO ENAME      JOB              MGR HIREDATE         SAL       COMM
---------- ---------- --------- ---------- --------- ---------- ----------
    DEPTNO
----------
      7369 SMITH      CLERK           7902 17-DEC-80        800
        20

      7499 ALLEN      SALESMAN        7698 20-FEB-81       1600        300
        30

      7521 WARD       SALESMAN        7698 22-FEB-81       1250        500
        30

     EMPNO ENAME      JOB              MGR HIREDATE         SAL       COMM
---------- ---------- --------- ---------- --------- ---------- ----------
    DEPTNO
----------
      7566 JONES      MANAGER         7839 02-APR-81       2975
        20

      7654 MARTIN     SALESMAN        7698 28-SEP-81       1250       1400
        30

      7698 BLAKE      MANAGER         7839 01-MAY-81       2850
        30

     EMPNO ENAME      JOB              MGR HIREDATE         SAL       COMM
---------- ---------- --------- ---------- --------- ---------- ----------
    DEPTNO
----------
      7782 CLARK      MANAGER         7839 09-JUN-81       2450
        10

      7788 SCOTT      ANALYST         7566 19-APR-87       3000
        20

      7839 KING       PRESIDENT            17-NOV-81       5000
        10

     EMPNO ENAME      JOB              MGR HIREDATE         SAL       COMM
---------- ---------- --------- ---------- --------- ---------- ----------
    DEPTNO
----------
      7844 TURNER     SALESMAN        7698 08-SEP-81       1500          0
        30

      7876 ADAMS      CLERK           7788 23-MAY-87       1100
        20

      7900 JAMES      CLERK           7698 03-DEC-81        950
        30

     EMPNO ENAME      JOB              MGR HIREDATE         SAL       COMM
---------- ---------- --------- ---------- --------- ---------- ----------
    DEPTNO
----------
      7902 FORD       ANALYST         7566 03-DEC-81       3000
        20

      7934 MILLER     CLERK           7782 23-JAN-82       1300
        10

14 rows selected.

SQL>

See the data returned.
HTH
Aman...

Tags: Database

Similar Questions

  • Oracle 10g - problem with "DELETE from TABLE WHERE ID in (1,2,3)" (use cfqueryparam)

    Hello, everyone.

    I have problems with executing a DELETE statement on an Oracle 10 g server.

    DELETE 
    FROM tableA
    WHERE ID in (1,2,3)
    

    If there is only a single ID for the IN clause, it works.  But if more than one ID is provided, I get an error message "SQL command" not correctly completed.  Here's the query as CF:

    DELETE 
    FROM TRAINING
    WHERE userID = <cfqueryparam cfsqltype="CF_SQL_VARCHAR" value="#trim(form.userID)#">
         AND TRAINING_ID in <cfqueryparam value="#form.trainingIDs#" cfsqltype="CF_SQL_INTEGER" list="yes">
    

    Someone at - it works with Oracle that can help me with this?  I'm a developer experienced in MS - SQL; Oracle is new to me.

    Thank you

    ^_^

    So much worse... a colleague just told me I should always use parentheses around the values in the IN clause.

  • Delete from Table on the Cancel button.

    Hello

    I am facing problem funny.

    I created the form with the report page and I have option to implement send e-mail on the Page so I am attaching a document more with email.if I attach document then it goes into the DUMY_DOC_FILE table.

    I create a process
     
    
    delete from DUMY_DOC_FILE .
    
    Process Point IS ON Submit -After Conmputation and Validation 
    
    
    On Page No 6.
    If I press the button Cancel Button.This is redirecting on page no. 4. not my Code on Page 6.
    page is redirect to 4 but the doc don't delete Table of DUMY_DOC_FILE.

    How to remove Doc from Table if I press the Cancel button.

    Thank you

    Published by: 805629 on January 13, 2011 05:25

    Published by: 805629 on January 13, 2011 23:49

    Published by: 805629 on January 14, 2011 12:43 AM

    This conditional validation_, so that it does not cancel send button (for example: *: ASK! = 'NAME of the BUTTON' *)

  • delete * from &lt; table &gt;

    Hello

    Is it possible to use
    delete * from <table_name>;
    When I tried it gave me error
    delete * from temp
    Error at line 1
    ORA-00903: invalid table name
    but on his watch as possible page
    http://psoug.org/definition/DELETE.htm
    So what is the true value.

    It is false. There has never been an option ' *' in the DELETE syntax. Here's the Oracle 7 documentation to REMOVE:

    http://download.Oracle.com/docs/CD/A57673_01/doc/Server/doc/SQL73/ch4a.htm#toc115

    Perhaps the author meant that the word OF key is optional? (I never use it.)

  • After that Avast Anti-virus where infected files have been deleted from Windows now reports "not authentic".

    run Avast boot time virsu scan... for a few filoes have been deleted as infected... when the widows restarted I received a ": successful Activation" screen but now the lower right corner shows "This is not a version of windows geniune" how, why?  I paid a lot of money for windows ultimate...

    Some tutorials for you...

    Windows Vista Validation issues:
    Windows is not genuine.
    A response from Keith, Microsoft Support, moderator. Date: April 29. 2010
    http://social.answers.Microsoft.com/forums/en-us/VistaInstall/thread/6efea9fd-70a9-4530-88c8-93fd7b2d5484
    How to contact a Microsoft Product Activation Center
    http://support.Microsoft.com/kb/950929 submit a request for technical support for Windows genuine
    http://Windows.Microsoft.com/en-us/Windows/help/genuine/submit-request?displaylang=en

    For the benefits of others looking for answers, please mark as answer suggestion if it solves your problem.

  • E-mail from Apple works does not on El Capitan

    Just upgraded to El Capitan and email dosent work properly. E-mails circulating to correctly, but if I want to reply to or forward an email it just happens with a blank page and then I can't get rid of him as the button minimize is the only one that works. Therefore, to have a line on the bottom of the office emails that disappear only if I restart the computer. Can someone please

    See if that helps.

    Compose window disappears and reappears

  • DELETE THE TABLE (...) does not

    Hello

    I want to remove some lines from a collection (nested table), but the following statement does not work

    I'm in vaAtcGroups.first... vaAtcGroups.last * DELETE OF TABLE (tmp_drugTable) WHERE v2DrugATC LIKE vaAtcGroups (i) | '%';*
    end loop;

    the table variable is declared and I use it before, just remove it won't work (at least according to this). I always get the error message PL/SQL: ORA-00903: invalid table namepointing to tmp_drugTable.

    There must be a way to do this, I can't see it :)
    Maybe someone else can

    Thank you

    maschlegel wrote:
    Thanks for the explanation.

    You can put your data into a global temporary table and then work with SQL. Data will exist only for the duration of the session or until you do one commit (depending on the way in which you set the TWG).

    That's exactly what I look at you now :)
    I tried to put the following in my inside, but he dislikes the syntax

    (DrugTable) CREATE TABLE TEMPORARY global
    nDrugId number (11.0).
    v2DrugUnit varchar2 (50).
    v2DrugIntervalNumber varchar2 (2000).
    nDrugIntervalId number (11.0).
    v2DrugName varchar2 (50).
    v2DrugATC varchar2 (10)
    ) ON COMMIT DELETE ROWS.

    I tried in the BLOCK IS and after BEGIN, but it gives me the error 'encoutered symbol create when waiting for the next' and then nothing?

    In General, a global temporary Table, you create a time and simply leave it is there to be used as and when you need. that is, you don't need to create dynamically at run time. If you really really really issue when executing DDL statements then you must use the EXECUTE IMMEDIATE to do, because cannot you issue directly code DML, PL/SQL DDL only may be issued directly.

  • Sent items from MS outlook do not appear in Thunderbird, but it works in the reverse (envoys since Thunderbird appears in Outlook). How to solve this problem?

    Sent items from MS outlook do not appear in Thunderbird, but it works in the reverse (envoys since Thunderbird appears in Outlook). How to solve this problem?

    I guess you have a pre existing account using the POP Protocol, that not only downloads the contents of the Inbox.

    Hotmail, Live, MSN, Outlook dot com now support IMAP which is a synchronized messaging service, changes in one are reflected in the other.

    File menu (alt + F) > New > existing e-mail account and add your account to the Thunderbird again. Make sure you have "account type selected IMAP and your all synchronized will.

    If it's like my account, your IMAP e-mail account will come with a subfolder under the pop called deleted folder that contains all mail I have downloaded in the past years.

    If you right-click your \new IMAP account in the folders pane on the right immediately after you create it and choose to subscribe you can unsubscribe from this folder if you don't see it

  • "Show my windows and tabs from last time ' does not work in version 3.6.8

    I select "show my windows and tabs from last time ' on the Options window - Panel general"when firefox starts", but it opens as my home page every time I start firefox.

    I tried this on two different computers. Both of them have the same problem.

    It worked fine in previous versions, but it does not work in version 3.6.8.

    If you use delete, search and download Firefox browsing history in Firefox 3.5 and later versions to clear the 'browsing history' the closing of Firefox then in restaurant tabs in the last session ("Save and exit" or "show my windows and tabs from last time ') does not work.

  • How to remove a domain controller that was removed from the Internet works but not demoted

    How to remove a domain controller that has been remove from the Internet works but not demoted

    got two domain controllers and been deleted but not retrograde

    can help pls

    Hello

    Your Windows is better suited for the directory on TechNet Services. You can follow the link to ask your question: http://social.technet.microsoft.com/Forums/en-us/winserverDS/threads

    I hope this helps.

  • Smartphones from blackBerry BES Question: when emails deleted from Outlook/exchange inbox why not email get removed from BB?

    Is - this b/c, the Exchange is only 'forwarding' mail for BB, do not receive any communication in return? But then why can the BB delete an e-mail message at the same time the BB device and the exchange server (if this option is selected)?

    I really need the BB to update the same as my Inbox with my exchange server, I will not be a happy camper if it does not recognize the emails that I moved into or deleted from the outlook/exchange Inbox subfolders, as my old Treo did... Is there some setting I am missing?

    Or is this what work of BB?

    Well hallelujah, is a tech BB saw my post and fixed a few BES script, or, I solved the problem by changing the setting in the options to "HIDE MESSAGED after HAVING REMOVING", I think it's the only setting I changed and I don't know if fixed it or not, but its not working as it should now.

  • RMAN delete policy has not worked and not delete outdated backup

    Hi all

    I am facing a problem this obsolete backup is not delete unwanted backup.

    I used to take level 0 once weekly and cumulative incremental in 3 times a day.

    I have 2 TB hard drive, every week, I used the backup from command remove obsolete based file can delete based on my redundancy strategy 1.

    The previous week it works fine and deleted obsolete backup based on the deletion policy. but this week when I try to use the delete obsolete command, it is not removed and the hard drive is always full and I couldn't take later backup.

    It's live server, I need to take the free space on the hard drive. Please help me.

    You will find details of error that I met in the log file.

    output channel: C1

    output channel: C2

    RMAN-00571: ===========================================================

    RMAN-00569: = ERROR MESSAGE STACK FOLLOWS =.

    RMAN-00571: ===========================================================

    RMAN-03002: failure of backup so archivelog command at 05/05/2015 10:57:14

    ORA-19502: write error on file 'G:\RMAN\AWSPROCESS\BACKUP\AWSPROCESS\BACKUPSET\2015_05_05\O1_MF_NNND1_TAG20150505T090032_BNJGC9RR_. BKP", the number of block 7227648 (block size = 8192)

    ORA-27070: async read/write failed

    OSD-04016: error queuing an asynchronous i/o request.

    S/O-error: (OS 112) there is not enough space on the disk.

    Your backup on May 02 is not a valid backup, then you can try something like:

    RMAN > delete database backup completed after 'sysdate-6 ";

  • CS5, installed from a backup does not work in the new iMac w / El Capitan; the discs moved

    My 2011 iMac has a failing hard drive. I downloaded a full backup, including the CS5, in a new iMac running El Capitan. None of the Adobe programs will run, even after I installed Java SE 6 & restarted. A Setup from disks, starting with Acrobat 9 Pro disc and after dragging the applications icon, gave me this: "the operation cannot be completed because one or more required items be found.» (Error code - 43) »

    I deleted programs meeting CS5, rebooted and tried to load again from the disk of Acrobat 9 Pro. After dragging the applications icon, I got this: ' the finder cannot complete the operation because some data in "" cannot be read or written. ". (Error code - 36) »

    Updated his computer at El Capitan my wife and charge of Java SE 6, and his CS5 still works. What can be done in my case? Thanks to all in advance!

    Download from a backup will not work.

    You must install it.

    https://helpx.Adobe.com/Creative-Suite/KB/CS5-product-downloads.html

    But CS5 wil cause a lot of errors on El Capitan.

    They simply are not (fully) compatible.

    Just search for it on the forum, you will find a lot of threads.

  • 11.2.3 Oracle dynamic sampling works is not on table with locked statistics, NULL

    I work in a development environment where the statistics are locked for all schemas. Some of these table objects have had their statistics unlocked and collected manually. We have the level of dynamic sampling set to 4.

    When I perform queries on this particular scheme, I can say that dynamic sampling isn't being run because I do not see any other session running in the OEM other than my request.

    Any ideas?

    You can check the level of dynamic sampling of the plan by querying V$ SQL_PLAN. Column OTHER_XML. For example:

    11.2.0.3... 4 3346460612...

    Also this info is printed according to dbms_xplan.display_cursor (). For example:

    Select * from table (dbms_xplan.display_cursor('79y5x009ytcav',1));

    PLAN_TABLE_OUTPUT

    ---------------------------------------------------------------------------

    SQL_ID, 79y5x009ytcav, number of children 1

    -------------------------------------

    Select count (*) from...

    ...

    Note

    -----

    - dynamic sample used for this survey (= level 4)

    Post edited by: Mihael

  • Remove the dialog box no longer appears. How can I get the dialog box to delete return? I want to delete the pictures from my hard drive not only lightroom

    I use Lightroom as my main photo organization, so when I want to delete a photo, I want to be able to delete if my hard drive most of the time, I rarely remove photos from catalogs or collections, so having only not the pop-up dialogue box more is a real problem for me.

    Also, what would be a good way to discover photos that has not removed the disc so I can delete them? is it possible that I can synchronize one catalog to another? @

    You try to delete from disk or a Collection?  If the attempt to delete a Collection, it does not work.  You must use the files if you also have the ability to delete from the drive of

Maybe you are looking for