Deletion of the data of a partition of a table

There is a duty to remove data from a particular partition in our Env PROD.

Please let me know the syntax for the same thing.
It is also possible to truncate a partition?

DB version is 10.2.0.4 and Solaris 10 operating system

Kind regards
Narayan

Published by: user7202581 on April 14, 2013 12:11 AM

user7202581 wrote:
We started with the delete and its been running for 6 hours now.
Log faster?

TRUNCATE is always faster than DELETING; regardless of the partition or not.

Tags: Database

Similar Questions

  • I CAN QUERY A TABLE EVEN AFTER THE DELETION OF THE DATA FILE

    Hello

    Can someone explain to me the reason why I am able to interview some tables even after the deletion of the data that are associated with file?

    SQL > select table_name, tablespace_name from dba_tables where owner = 'SCOTT ';

    TABLE_NAME, TABLESPACE_NAME

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

    TEST2 USERS

    TEST USERS

    SALGRADE USERS

    USERS OF BONUS

    USERS OF THE EMP

    USERS OF DEPT

    6 selected lines.

    SQL > exit

    Disconnected from the database to Oracle 11 g Enterprise Edition Release 11.2.0.1.0 - Production

    With partitioning, OLAP, Data Mining and Real Application Testing options

    [oracle@localhost orcl] $ rm /app/oracle/oradata/orcl/users01.dbf

    [oracle@localhost orcl] $ sqlplus scott/scott

    SQL * more: Production version 11.2.0.1.0 on Mon Mar 30 21:35:54 2015

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

    Connected to:

    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production

    With partitioning, OLAP, Data Mining and Real Application Testing options

    SQL > select count (*) from test2;

    Select count (*) from test2

    *

    ERROR on line 1:

    ORA-01116: error opening the database file 4

    ORA-01110: data file 4: ' / app/oracle/oradata/orcl/users01.dbf'

    ORA-27041: could not open the file

    Linux error: 2: no such file or directory

    Additional information: 3

    SQL > select count (*) of the test;

    COUNT (*)

    ----------

    5000

    SQL >

    The first output is as expected. But why am I still able to query the table of test, even if the data file has been deleted.

    Hello

    The process of database have a file handle for the data file - this remains even when the file is deleted (it disappears from the normal file system navigation)

    You can see if you have lsof installed

    just try

    lsof | grep datafile_name

    Once the database is restarted and the released file handle so you will not be able to do this any more - and in fact you will get errors when it can't find the file.

    See you soon,.

    Rich

  • Hi I want to erase all the data from my current phone if I erase content and settings would be deleted all the data off my sim card? Thanks for your help

    Hi I want to erase all the data from my current phone if I erase content and settings would be deleted all the data off my sim card? Thanks for your help

    Erase the data on your phone will not erase the data on the sim card.

  • What happens if I delete all the data of the Web site on my iPad mini?

    What happens if I select the option DELETE all THE DATA of the WEB site under Safari in the settings on my iPad mini?

    It clears all cookies, data, and the history of Safari.

  • Automatic updates of Vista have deleted all the data on my desk.

    Recently my laptop Toshiba running Vista business done the automatic updates during the night, the morning I found that he had deleted all the folders, files and icons on my desktop (including the important work files), had changed the wallpaper, reset all my Internet properties and changed the login screen.

    What I can do, are very important files.

    I tried to restore the system to an earlier date, but this made no difference.

    I also tried to contact Microsoft, who acknowledged my report and said they would be back to me within one business day, which was seven days ago.

    Hi mbuk,.

    Welcome to Windows Vista answers Forums!

    With automatic updates, you want to lose the data stored on the system.

    Once removed the HDD data can't be recovered. However, you can use your favorite search engine to browse third-party data recovery software and use this software to recover data.

    Note: Using third-party software, including hardware drivers can cause serious problems that may prevent your computer from starting properly. Microsoft cannot guarantee that problems resulting from the use of third-party software can be solved. Software using third party is at your own risk.

    You can also view the following link to recover lost or deleted files and try the steps:

    http://Windows.Microsoft.com/en-us/Windows-Vista/recover-lost-or-deleted-files

    Hope this information is useful.

    Jeremy K

    Microsoft Answers Support Engineer
    Visit our Microsoft answers feedback Forum and let us know what you think

  • No access to the data of a partition of a disk

    Windows Vista automatically starts the repair of my D: drive. Many errors have been reported and fixed.

    I now see the D: drive in the Windows Explorer, but no access to the data on D: is possible. The bar that shows the used/free space is not shown. A second partition on the hard drive works fine.

    In disk management I find D: drive with all the information on the used/free space, no error is reported.

    No idea how to fix?

    Any help is cordial welcome.

    Your machine to HD will have a free test bootable utility, for example WD SeaTools

  • Can photos be deleted from the data store directly?

    Hello

    I just doubt. Can shapshots be deleted directly from the data store.

    I checked the Snapshot Manager, but was not able to locate snapshots in it, but at the same time there were three snapshots in particular virtual machine data store. What it means?

    And what is my isNativeSnapshot = 'no'?

    I just doubt. Can shapshots be deleted directly from the data store.

    No, snapshots work as a string. Deletion of one of the links in the chain breaks the chain. Please take a look at http://kb.vmware.com/kb/1015180 to see how snapshots work.

    I checked the Snapshot Manager, but was not able to locate snapshots in it, but at the same time there were three snapshots in particular virtual machine data store. What it means?

    Information about snapshots are kept in .vmsd the virtual machine folder. If this file is corrupt - for some reason-you won't see the correct string snapshot in the Snapshot Manager.

    Please create a list of all files in the folder of the virtual machine (dir *. * /oen > filelist.txt (for Windows) or ls-lisa > filelist.txt (for Linux)) and after (tie) the filelist.txt, file .vmx VM as well as the file .vmsd for your next post.

    André

  • Deletion of the data store

    Hello

    I deleted a data on a cluster through a host store. The data store is not longer available on all hosts, but it still appears on home / inventory / data warehouses.

    The hosts are in 4.1.0 (build 260 247), the vCenter is 4.1.0 Build 258 902.

    The data store has been 200 GB and used on 10 hosts, all with the same version.

    The "Delete" option is not available on the data (by clicking right on) store, the data store is no longer visible on the hosts.

    How can I clean the records of data store on the inventory of the data store?

    Thank you very much in advance for your answers.

    KB http://kb.vmware.com/kb/1026661 explains the process of how to remove the vCenter Server DB data store in a case like this.

    André

  • Deletion of the data loaded into the Planning

    We loaded data using ODI of planning on an intersection. I need to remove the data and reload to planning on the same intersection. How can I delete a single charge and reload the data? I don't want to clean up the database and recharge start. I just have to clean an intersection and load again.


    Thank you for your help

    Create a calc script clear the area of the database and run before you load the data again.

    See you soon

    John
    http://John-Goodwin.blogspot.com/

  • Change the 'Date' of a column in A table, the new column in the Table b:

    I'm trying to pull a TABLE_A Date and change the year at a date and popluate it into a new table. I would also like to put on the KP to TABLE_A, so that I can create a link to the master record.

    In my example I use SYSDATE to my current date. Once I get the script working, I want to shoot the Calander_Date of my "current schedule" by their SUMMIT.

    1 INSERT INTO TABLE_B (NAME_ID VALUES, Date, New_Date ())
    2 NAME_ID, (it is a column OF TABLE_A).
    3. DATE, (it's also a TABLE_A Colum)
    4 TO_CHAR(DATE,'DD') | » -'||
    5 TO_CHAR(DATE,'MON') | » -'||
    (6 TO_CHAR(SYSDATE,'YY'))
    7. FROM TABLE_A
    8. WHERE TO_CHAR(DATE,'MON') = TO_CHAR (SYSDATE, 'MY');

    Needless to say that it does not work! I am very new to SQL and APEX. I tried also incorporate some INSTRUCTIONS SELECT, as shown below, but even now of (trying to figure out out to calculate the TO_CHAR FROM DUAL and TABLE_A for the "DATE" column)

    1 INSERT INTO TABLE_B (NAME_ID VALUES, Date, New_Date ())
    2. SELECT NAME_ID IN THE TABLE_A,
    3. CHOOSE DATE TO TABLE_A,
    4. SELECT TO_CHAR (DATE, 'DD') | » -'||
    5. SELECT TO_CHAR(DATE,'MON'). » -'||
    6. SELECT TO_CHAR (SYSDATE, 'YY')) OF
    7. BASED ON NAMES
    8. WHERE TO_CHAR(DATE,'MON') = TO_CHAR (SYSDATE, 'MY');

    According to the changes I I usually get the following two errors:

    ORA-0933: SQL command not properly ended (in the first example)
    ORA-00936: Missing Expression (in the second example).

    Appreciate all the thoughts that you all might have.

    LEONHARK

    Oh, and I forgot to mention, special attention for the day/month/year. The examples I cited are for digital day/month/year. If they are stored at May 1, 2008, replace the "MM" above "LUN."

    Good luck!

  • SELECT the data inserted into a global temporary Table in a stored proc

    A stored procedure is run from Oracle SQL Developer to insert data into a global temporary table. A SQL (in Oracle SQL Developer) worksheet is open to run a SELECT query to retrieve the data from the temporary table overall which was populated in the stored procedure. No row is returned. I guess it's because the stored procedure and the SELECT statement executed in different sessions.

    Is it possible to run the stored procedure in Oracle SQL Developer and then execute a select statement on the temporary table overall which was filled in the stored procedure by using the same connection so that the data can be extracted?

    I use version 1.5.1 build HAND-5440 of Oracle SQL Developer.

    In a worksheet, do something like

    Start
    insert_proc;
    end;

    Select * from my_temp_table;

    Place the cursor on each statement in turn and Press f9 (where it all began... the end is a single statement.

  • I want to delete all the data from my iphone 4S I forgot the code

    I want to give my iphone 4s to my mother and I want to delete all data.

    When I try the device ask to enter the code. I don't know witch code should

    I think you speak for the access code.

    If you have forgotten the password for your iPhone, iPad or iPod touch, or your device is disabled - Apple supports

  • So my ipod was a friends account on this topic, so I deleted all the data on it, and now, all this shows is a button to itunes with the short side of the presentation of the charger to it? will not do anything else

    I erased my information from friends on my ipod cause she has created an account on it, so I deleted his email, images, music and everything and now its a screen with a button itunes on it and the small part of my white charger pointing to it. It won't do anything else and it is fully charged.

    Hello

    Please post your question in the following forums.

    iPod: Apple support communities:
    https://discussions.Apple.com/community/iPod

    Concerning

  • Deletion of the data file

    Hi all
    I want to remove the file from my ASM instance data. I gave a bad reputation in my data file and I want to remove now.

    SQL > select file_name, nom_tablespace, ONLINE_STATUS from relative_ where nom_tablespace = 'USERS ';

    FILE_NAME NOM_TABLESPACE ONLINE_STATUS
    ------------------------------ ----------- ----------------

    + RECOVER the USERS DATA/orcl/datafile/mobiles2


    Please help me solve this problem.

    Thank you
    Krish

    It seems that if you want to return your tablespace return, you must first restore the file and retrieve it. If this isn't the case, you can use tracking to clean your system catalog:

    Drop tablespace USERS, including content and data files;

    otherwise, work, use:

    ALTER database datafile '+ DATA, orcl, datafile, mobiles2' drop offline;
    Drop tablespace USERS, including content and data files;

    Hüsnü Sensoy

  • Comparison of the data of several rows in a table - based on the primary key

    Currently I have a select statement that returns hundreds of records.  Each returned record is linked to A NUMBER of ORDER this order number has a recipe.  (a bit like a cooking recipe).  Each recipe has many records in the database related to this order number and records should be compared to records in a table that bind to a specific primary key...  (I have already developed the logic to isolate what PK I need).  If all these records that are returned by the select statement below does not match all the records containing PK in the table below, I need to get the next PK and compare all these recordings for select statements return.

    See below for a better understanding. Need a good example detailed on how to solve my problem here.

    Just to help you understand:

    Each element of the recipe is 3 parts (side, ref_des, part_number).  1 single recipe can have several parts (where the part_number), and each of these pieces should be placed on the lower side or top of the Board that is there "side" comes into play.  Same thing with Ref_Des.

    What is going on

    Select statement returns the RECIPE of ORDER NUMBER A.  There will be multiple records returned by this query.

    Select the Return statement:

    • Side
    • Ref_Des
    • Part_Number

    Example of return:

    B c17 75145-2

    T f14 89242-8

    B s12 45123-3

    etc,

    In general - what I need to do:

    There is a table called AUTO_RECIPE_DETAILS.  I take all of the records returned by the select query above and compare for each record in this table relating to the recipe 30319-000001.  30319-000001 a number of records.  It is the primary key for a whole recipe as seen above.  This primary key is bound the number of data records in this table.  The comparison is to see if all records under RECIPE_NAME 30319 -000001 match all the records returned by the select statement.

    IF IT DOES NOT MATCH: recover the following recipe in this table below 30319 -000002 and make the same comparison.

    Here's a perfect example of what the table looks like: (AUTO_RECIPE_DETAILS)


    RECIPE_NAME SIDE REF_DES PART_NUM

    -30319-000001 C16 87595-1 B

    -30319-000002           T B14 74150-4

    -30319-000001 T B14 34251-2          

    -30319-000001            T F24 84180-7

    -30319-000002 T B12 13710-8          



    It is the solution to my original question.  By this thread, it's the right answer and I hope this helps someone who is trying to compare two arrays element-by-element.  In the end, the advice given in this thread were correct and I will be using all of your suggestions and the scrapping of this.  Thank you everyone for your help though.

    FOR index_p IN pid_recipe. FIRST... pid_recipe. LAST

    LOOP

    Result WHEN the OUTPUT = 1;

    FOR index_d IN details_recipe. FIRST... details_recipe. LAST

    LOOP

    IF (pid_recipe (index_p). SIDE = details_recipe (index_d). SIDE)

    AND (pid_recipe (index_p). REF_DES = details_recipe (index_d). REF_DES)

    AND (pid_recipe (index_p). PART_NUM = details_recipe (index_d). PART_NUM)

    THEN

    EXIT;

    ON THE OTHER

    DBMS_OUTPUT. Put_line("IT WAS NOT a MATCH");

    result: = 1;

    EXIT;

    END IF;

    END LOOP;

    END LOOP;

    DBMS_OUTPUT. Put_line('LOOP OUT');

Maybe you are looking for