Doubled entries in table

Through a mistake I inserted data two times in a table. As they are a lot (about 6mio rows) and I am not able to get the source data again: IS THERE A WAY TO ELIMINATE THE DOUBLE ENTRIES?
Thanks,
Walter

CREATE TABLE <tabletobecreated> AS
SELECT DISTINCT * FROM <tabletobecopied>;
DELETE FROM <tabletobecopied>;
COMMIT;
INSERT INTO <tabletobecopied>
SELECT * FROM <tabletobecreated>;
COMMIT;try this on you development or test instance first.

Similar Messages

  • I have to make Multiple entry at table maintanance at a time

    Hello all,
    My requirment is to enable the multple user can loginto the same table for making there entry simultaneosuly .
    i have created the table and table maintance as well. and i have created the new lock object and added the code accrdingly and i have used the custom fm which is generated in the tablemainta  function group.
    forex: table xyz
    user 1 , 2, 3, 4, 5,so on..
    table should allow all user tomake there entry at time and the entry edited one user should be disabled to other user.
    I have gone the forum i didnt found the correct one ..plz guide me ..plz find the attached code .i got this code and referredthe samein my prog ..any suggestions on the below.
    1.       Create table ZTEST_SHUKS3.
    2.       Create table maintenance generator for the table. 
    3       Create lock object EYTSS_E433SH in SE11. Give it name as EZTEST_SHUKS3. 
    4       create a report  ZREP_SHUKS3 and transaction code ZTEST_SHUKS3  to call this report. This tcode will call table  mainatance     generator of table ZTEST_SHUKS3 . 
    5  create the report as below
    6 Now open table maintenance function  group(ZTEST_SHUKS3)  in SE80.We know for table maintenance SAP automatically creates code in the function group. Now we will make some modification in that existing code to change the behavior. Open the screen you created through table maintenance and add one module. 
    screen: 0001
    double clik on screen and add one module in PBO of the screen
    loop at extract with control
    tctrl_ZTEST_SHUKS3 CURSOR NEXTLINE.
    MODULE LIST SHOW LISTE
    ADD HERE
    MODULE m_change_locking
    Check the code below to be added in the module m_change_locking. 
    MODULE m_change_locking OUTPUT.
    *Call the function module corresponding to the lock object we created
      CALL FUNCTION 'ENQUEUE_EZTEST_SHUKS3'
        EXPORTING
          matnr          = ztest_shuks3-matnr
          werks          = ztest_shuks3-werks
        EXCEPTIONS
          foreign_lock   = 1
          system_failure = 2
          OTHERS         = 3.
      IF sy-subrc NE 0.
    row is locked..hence gray..
        LOOP AT SCREEN.
          screen-input = 0.
          MODIFY SCREEN.
        ENDLOOP.
      ENDIF.
    ENDMODULE.                 " m_change_locking  OUTPUT 
    REPORT  zrep_shuks3.
    **Selection range for view maintenance
    DATA:
      BEGIN OF selekttab OCCURS 1.         "Selektionsbereich
            INCLUDE STRUCTURE vimsellist.
    DATA: END OF selekttab,
    **Table of inactive CUA functions for view maintenance
    BEGIN OF excl_cua_funct OCCURS 1.    "inaktive CUA-Fkt bei View-Pflege
            INCLUDE STRUCTURE vimexclfun.
    DATA: END OF excl_cua_funct.
    DATA: lt_enq_del TYPE STANDARD TABLE OF seqg3,
          lt_enq_read TYPE STANDARD TABLE OF seqg7,
          lw_enq_read TYPE seqg7,
          lw_enq_del TYPE seqg3,
          lv_subrc TYPE sy-subrc.
    *Read all the lock details in system
    CALL FUNCTION 'ENQUE_READ2'
      EXPORTING
        gclient = sy-mandt
        gname   = ' '
        guname  = '*'
      TABLES
        enq     = lt_enq_read.
    *We will search entry for table level lock for our table
    LOOP AT lt_enq_read INTO lw_enq_read
    WHERE gname EQ 'RSTABLE'
    AND   garg CS 'ZTEST_SHUKS3'.
      MOVE-CORRESPONDING lw_enq_read TO lw_enq_del.
      APPEND lw_enq_del TO lt_enq_del.
    ENDLOOP.
    *Delete table level lock entry for our table
    CALL FUNCTION 'ENQUE_DELETE'
      EXPORTING
        check_upd_requests = 1
      IMPORTING
        subrc              = lv_subrc
      TABLES
        enq                = lt_enq_del.
    *Now call the table maintenace generator.
    CALL FUNCTION 'VIEW_MAINTENANCE_CALL'
      EXPORTING
        action               = 'U'
        view_name            = 'ZTEST_SHUKS3'
        show_selection_popup = 'X'
      TABLES
        dba_sellist          = selekttab
        excl_cua_funct       = excl_cua_funct.
    I followed the same steps but still not getting the multiple user enable .
    plz help
    regards
    Raju
    Edited by: abaprthree on Jul 22, 2009 7:54 PM

    Hi,
    I think you are looking for the report which will allow only for entries not for change. In this case, at PBO you write the code to make all the rows in display mode which have records using LOOP at SCREEN .....ENDLOOP. When you click on on NEW ENTRY button, add blank rows and put user entries. When you save,check for existing entries in the table because many users are entering the data at the same time, so check for duplicates KEY entries and UPDATE the table on SAVE button. If you will go in this way, I don't think you have to go for LOCK object. It's required only if you are going for EDIT mode.

  • Double entry for details from draft to invoice

    Hi..
    im doing a draft to invoice uploading via SDK, my problem , when im doing the uploading of components and changing the profit cost center and warehouse code, the original warehouse and cost center also  affair on the invoice, which in return, the invoice created had a double entry the stock movement also recorded this transaction.
    thanks
    loren

    Hi Gordon
    Thank you for your response, that exactly what i did, change the warehouse and profit cost center from the draft before the uploading into the invoice, I do also the checking if the  data (odrf, drf1 table)  for double entry and output from the drafts standard form (display) change the warehouse and profit cost center. Result show the ideal result no duplicate data , warehouse and profit cost center where correct, but still when uploading the data from the draft into the invoice via sdk , the default warehouse and profit cost center where also created and included on the new invoice. So i would like to know what will be the correct procedure or way to transfer this data corrently using SDk
    thanks
    loren

  • Delete an entry from table T527X.

    Hello Gurus,
    How can we delete an entry from table T527X from se11/se16? Or is there any other transaction by which we can delete this entry? I can not delete the org unit as this org unit is not having any name and the ID is: 00000000. I created this entry using SE11 -> utilities -> Create entry.
    Thanks,
    Chakri.

    When you say select the entry or you double clicking?
    You can try this.. simply select the check box against that entr in the displayed list and then use the menu option Table Entry--> Delete
    Other than, this I can't think of another option.. ofcourse you can always have  a simple custom program  with a couple of lines of code to delete a table entry.
    ~Suresh

  • How can i  add entry in table BSP_DL_XMLSTRX2 for creating a copy of a view

    hi
    i want to copy in a CRM_UI component view the configuration of the view and want to save the copy with a
    different object type. But F4 value help only provides ( in crm_ui component workbench) me the value <DEFAULT> as for that view there is only one entry in table
    BSP_DL_XMLSTRX2 and for object type = <DEFAULT> and when i enter something different i get the error that this object type does not exist.
    (call method CL_BSP_DLC_XML_STORAGE2=>GET_EXISTENCE_FOR_VIEW
        exporting
          IV_COMPONENT       = ME->CURRENT_CONFIG_KEY-COMPONENT
          IV_VIEWNAME        = ME->CURRENT_CONFIG_KEY-VIEWNAME
        importing
          ET_CONTEXT_SEM_KEY = LT_CONTEXT
          ET_CONFIG_INFO     = LT_CONF_INFO.
    ---> result in only one line but i want to add another
    *so my questioin:
    where can i enter a new object type for a existing crm_ui view configuration

    Hello Britta,
    Its useful program to copy a view configuration.
    Best Regards,
    zafer,
    Edited by: Zafer Kuru on Dec 5, 2011 3:51 PM
    REPORT  z_copy.
    TABLES bsp_dcls_conf_semantic_key.
    SELECTION-SCREEN BEGIN OF BLOCK b1 WITH FRAME TITLE text-001.
    PARAMETERS     fr_comp  TYPE bsp_wd_component_name OBLIGATORY.
    PARAMETERS     fr_view  TYPE o2pageext OBLIGATORY.
    PARAMETERS     fr_role  TYPE bsp_dlc_role_key OBLIGATORY.
    PARAMETERS     fr_couse TYPE bsp_dlc_component_usage OBLIGATORY.
    PARAMETERS     fr_obty  TYPE bsp_dlc_object_type OBLIGATORY.
    PARAMETERS     fr_obsty TYPE bsp_dlc_object_sub_type OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK b1.
    SELECTION-SCREEN BEGIN OF BLOCK b2 WITH FRAME TITLE text-002.
    PARAMETERS     to_comp  TYPE bsp_wd_component_name OBLIGATORY.
    PARAMETERS     to_view  TYPE o2pageext OBLIGATORY.
    PARAMETERS     to_role  TYPE bsp_dlc_role_key OBLIGATORY.
    PARAMETERS     to_couse TYPE bsp_dlc_component_usage OBLIGATORY.
    PARAMETERS     to_obty  TYPE bsp_dlc_object_type OBLIGATORY.
    PARAMETERS     to_obsty TYPE bsp_dlc_object_sub_type OBLIGATORY.
    SELECTION-SCREEN END OF BLOCK b2.
    SELECTION-SCREEN BEGIN OF BLOCK b3 WITH FRAME TITLE text-003.
    PARAMETERS     request   TYPE trkorr OBLIGATORY.
    PARAMETERS     d_mode    TYPE flag.
    SELECTION-SCREEN END OF BLOCK b3.
    DATA :  iv_from_component         TYPE  bsp_wd_component_name,
            iv_from_viewname          TYPE  o2pageext,
            iv_from_role_key          TYPE  bsp_dlc_role_key,
            iv_from_component_usage   TYPE  bsp_dlc_component_usage,
            iv_from_object_type       TYPE  bsp_dlc_object_type,
            iv_from_object_sub_type   TYPE  bsp_dlc_object_sub_type,
            iv_to_component           TYPE  bsp_wd_component_name,
            iv_to_viewname            TYPE  o2pageext,
            iv_to_role_key            TYPE  bsp_dlc_role_key,
            iv_to_component_usage     TYPE  bsp_dlc_component_usage,
            iv_to_object_type         TYPE  bsp_dlc_object_type,
            iv_to_object_sub_type     TYPE  bsp_dlc_object_sub_type,
            is_transport_data         TYPE  bsp_dlc_config_transport_data.
    DATA:
      ls_from_config_data   TYPE bsp_dlcs_conf_data,
      lr_from_text_rep      TYPE REF TO cl_bsp_dlc_stext_repository2,
      lr_to_text_rep        TYPE REF TO cl_bsp_dlc_stext_repository2,
      lt_from_text          TYPE bsp_dlt_stxtrep2,
      ls_from_text          TYPE bsp_dl_stxtrep2,
      lv_to_context_id      TYPE bsp_dlc_context_id,
      lv_config_data_origin TYPE bsp_dlc_config_data_origin.
    DATA lt_xmlconf TYPE TABLE OF bspc_dl_xmlstrx2.
    DATA ls_xmlconf TYPE bspc_dl_xmlstrx2.
    DATA ls_xmlconf_check TYPE bspc_dl_xmlstrx2.
    is_transport_data-request = request.
    is_transport_data-display_mode = d_mode.
    SELECT SINGLE * FROM bspc_dl_xmlstrx2 INTO ls_xmlconf_check
                                          WHERE component = fr_comp
                                            AND viewname = fr_view
                                            AND role_key = fr_role
                                            AND component_usage = fr_couse
                                            AND object_type = fr_obty
                                            AND object_sub_type = fr_obsty.
    CHECK sy-subrc EQ 0.
    TRY.
        CALL METHOD cl_bsp_dlc_xml_storage2=>get_config_data
          EXPORTING
            iv_component           = fr_comp
            iv_viewname            = fr_view
            iv_role_key            = fr_role
            iv_component_usage     = fr_couse
            iv_object_type         = fr_obty
            iv_object_sub_type     = fr_obsty
            iv_only_spec_parameter = abap_true
          IMPORTING
            es_config_data         = ls_from_config_data
            ev_config_data_origin  = lv_config_data_origin.
      CATCH cx_bsp_dlc_config_not_found.
        RAISE config_not_found.
    ENDTRY.
    lr_from_text_rep = cl_bsp_dlc_stext_repository2=>get_instance(
                                             iv_component = fr_comp
                                             iv_viewname  = fr_view
                                             iv_role_key        = fr_role
                                             iv_component_usage = fr_couse
                                             iv_object_type     = fr_obty
                                             iv_object_sub_type = fr_obsty
    CASE lv_config_data_origin.
      WHEN cl_bsp_dlc_xml_storage2=>config_data_origin_c.
        CALL METHOD lr_from_text_rep->get_texts_c_for_context_id
          EXPORTING
            iv_all_langu = 'X'
          IMPORTING
            et_text      = lt_from_text.
      WHEN cl_bsp_dlc_xml_storage2=>config_data_origin_s.
        CALL METHOD lr_from_text_rep->get_texts_s_for_context_id
          EXPORTING
            iv_all_langu = 'X'
          IMPORTING
            et_text      = lt_from_text.
    ENDCASE.
    Edited by: Zafer Kuru on Dec 5, 2011 3:54 PM

  • To delete multiple entries in table control in module pool

    Hi,
    Please help me out to know , <b>how to delete multiple entries from table control</b> when multiple lines in table control are selected.
    Regards,
    Irfan Hussain

    hai,
        you can do it inthis way.
    in the PAI event.
    loop at <table control name>
      module del_itab.
    endloop.
    in the nodule,write the folowing code.
    if <tablecontrol>-fieldname = 'X'.
    delete <tablecontrol-itab>
    endif.
    cheers

  • SRM-EBP:  How to delete multiple entries in table BBP_DOCUMENT_TAB easier?

    We are running SRM 4.0 EBP on classic scenario.  I want to delete entries in table BBP_DOCUMENT_TAB easier and faster using FM BBP_DELETE_FROM_DOCUMENT_TAB.  Is there a standard program that calls this FM so that inputting the entries will be faster?  I see only CLEAN_REQREQ_UP but does not serve the purpose.  If none, how can I develop a program to achieve this?  Please help SRM Consultants.

    Hi,
    Please check note 535765, in it there is a special report that deletes entries from this table.
    I hope this helps,
    Kind Regards,
    Lisa

  • I am receiveing error while creating Z table: Entry in table TAORA missing

    Hi Experts,
    I am receiving "Entry in table TAORA missing" while creating Z table.
    Please help
    Edited by: N_niki on Jun 11, 2011 9:22 AM

    Hi
    1) Check for the DB System. The Table name in  "Entry in table TAORA missing", meant to save the "DATA CLASS of the ORACLE application"., OR
    2) check for the Data Class you Selected, on Creation of the Z Table, for which an Entry exists in the TAORA or the Available DATA CLASS in the TAORA Table to fix it.
    Regards
    Gopu

  • Error "No entry in table T589A for P" while creating new Infotype

    HI,
    I've created a new infotype (9605). All the tables, structures, screens etc. have been created using transaction PM01 successfully. But upon execution of Infotype from PA30, the infotype screen is displayed with the following error:
    "No entry in table T589A for P"
    Any input will be highly appreciated.
    Thank you,
    Farooq.

    Hi Farooq,
    Untill and unless the the field PSYST-IOPER is cleared explicitly in the program MP960500 (in PBO modules), this error should not occur.
    Also is this error is coming only for 9605 infotype ? Also is any other info availaible in the error message such as entry in table t589a is not available for which value of OPERA (INS, MOD, DEL, LIS etc) ?
    Regards,
    Shrinivas

  • Error "No entry in table T551A" while creating set work schedule rule.

    Dear Team,
    I am getting following error while creating set work schedule rule.
    Error "No entry in table T551A" for key 22 BBB [ here BBBB is my period work schedule]
    The actual prob is i configured all the necessary steps but when i tried to create work schedule rule im getting this error. Also, in the same screen there is one field DWS grouping initially value in this is 00 and gread mode. But after giving ES grp, holiday calander ID etc etc when i try to save that screen that value is chainging to 22 from 00.
    My ES grop=2 and PS grop=2 . Is that value is my ES and PS grouping..?? or some other thing.
    Request you to please help me out.
    Regards
    Shab.

    HI, there are 8 steps you need to do below:
    1. Group Personnel Subareas for the Daily Work Schedule
    2. Group Personnel Subareas for the Work Schedule
    3. Define Break Schedules
    4. Define Daily Work Schedules
    5. Define Period Work Schedules
    6. Define Employee Subgroup Groupings
    7. Define Groupings for the Public Holiday Calendar
    8. Set Work Schedule Rules and Work Schedules
    All of them belong to TIME MANAGEMENT. I think you miss some steps above.
    Please check it again.
    Regards!
    Minh

  • Restrict Double entry of condition type

    Hi All,
    How to control double entry of condition type at Item & header level in sales order????....any solution
    Thanks & best regards
    Umed

    Condition type settings V/06, Changes which can be made section maintain B- Automatic entry has priority , if condition record exist then system will not accept to enter manually.(If yours is autoamatic condition type.)
    If your condition type is manual and if you maintain 'C' - Manual entries has been priority or Blank - No lomitations, then i think we can not stop this.
    Regards,
    Ramesh

  • How do I get rid of double entries in my Contacts?

    I sync a 3rd party software, DejaOffice, from my iPad to my PC via Outlook. (DejaOffice is an integrated program with Calendar, Contacts, To-do List, and other features.) DejaOffice allows for syncing to Apple Calendar & Contacts. (Synicing to Contacts is especially important on my iPhone so it recognizes incoming calls in call display.) When I sync to Apple Calendar & Contacts, I often get double entries in both the Apple software, and DejaOffice. So, I have turned off syncing to Apple Contacts and Calendar from DejaOffice. I have just spent an hour deleting the double/triple entries in Contacts in my iCloud from my PC, and want to push the corrected list to my iPad & iPhone 5. I can't see how to delete the contacts in iPad or iPhone (which still have double & triple entries). If I turn on iCloud Contacts and Calendar in either device, it tells me it will merge the data, and I don't want the double entries any more, so I'd like to delete all contacts on iPad & iPhone, and then push the corrected iCloud list to both devices so they are all on the same page. I can't seem to figure out how to delete my Contacts or Calendar entries on iPad or iPhone so the merge only contains the corrected list from the iCloud. Can anyone help me with this?

    First, export your contact from iCloud.com and save them on your computer in a safe spot some where (like you desktop).  Use this to help you do this: http://support.apple.com/kb/PH3606
    Next, on both of your devices, go to Settings > iCloud and turn on contacts and select Merge. Then turn off contacts and select 'Delete form my [device]' when prompted.
    Now go back to iCloud.com and select a contact (yes they will all be messed up again) and select Command+A on a Mac or Control+A on a PC to select all of the contacts.  Tap the delete key on your keyboard (or right click /control click a contact and select delete).
    You iPhone, iPad and iCloud.com should not be empty for contacts.
    Go back to Settings > iCloud on both devices and turn on contacts again (you should not see merge this time).
    Next, go back to iCloud.com and import your contacts (those exported .vcards).  You can either drag and drop them into the empty contacts list in your web browser, or you can use the gear icon to import.
    You cleaned up contacts should import correctly into iCloud.com and sync to both of your devices.
    Good luck.

  • Logical system entry for table entry

    Hi,
      After system copy from one system name to another , I am facing some inconsistenices in various tables.
    The table entry can be seen in se16.But when I try to select entries from the same table using SELECT statement, table are not getting populated.
    I ran the BDLS also . How do I check the logical system entried for table where I have inconsistent entries?
    Thanks,
    Chitta

    Hello Chitta,
    But when I try to select entries from the same table using SELECT statement, table are not getting populated.
    what are you trying to populate?
    If your question is, its not showing anything... what error message you're getting? are you trying to run in the DB level?
    If you're getting error, that this object doesn't exist in the database then you might not be logging with correct user. its an SAP table, then its owner is the SAP schema user. If you login with the schema user, it should show in a normal select statement. But if you login with <sid>adm then you have to give the correct schema id before tablename.
    select * from <SchemaID>.<tablename>
    SchemaID may be sapr3, sapsr3, or sap<SID> depending on your release.
    Regards,
    Debasis.

  • How to create Infotype entry in table T777D

    Hi All,
    We have undergone Upgrade from 4.6C to ECC 6.0.
    Now we get an error while maintaining certain data infotype 0122 does not exists.
    I looked at the entries in table T777D in both the system. In older system the entry is there but not in the new system.
    When i tried creating the entry in this table the error comes 'Module pool program MP012200 is not present'. This program was there in 4.6C but is not there in ECC 6.0.
    How do we genrate this program or how do we create the entry for this infotype to correct the error.
    Is there any customizing settings that is required?
    Please advice.
    Regards,
    Vidya.

    Look at OSS [Note 546167 - Termination in PA10: Infotype 0122 does not exist|https://service.sap.com/sap/support/notes/546167]
    >Symptom
    >
    >When you edit the master data (transaction PA10) after you upgrade Release 4.6C to Release 4.70 or higher, a termination occurs and an error message is issued informing you that infotype 0122 does not exist.
    >
    >Other terms
    >
    >No entry in table T777D
    >
    >Solution
    >
    >In the 'Infotype attributes (Customizing)' view (extended table maintenance for view V_T582A), delete the entry for infotype 0122.
    >In the 'Infotypes - country-specific settings' view (extended table maintenance for view V_T582L), delete the entry for infotype 0122.
    Regards

  • Unable to create new entry in table that has no primary key

    Hi
       I have a table which is required to have no primary key (except mandt). After i generate table maintanance, when I go to create new entries, the table control to enter the new values does not appear. When I click on edit->new entries, it goes back to the fields tab of the table. Same when i check through SM30.
    If i maintain atleast one primary key, I am able to get the table control in new entries screen. However the requirement permits no primary keys except mandt. How can this be resolved?
    Thanks
    NM

    Hi,
    THE PROBLEM WITH UR TABLE IS
    YOU HAD DECLARED MANDT AS THE PRIMARY KEY AND THERE IS NO OTHER KEY IN UR TABLE
    iT'S NOT ALLOWING YOU TO ADD NEW ENTRIES BECAUSE MANDT IS THE ONLY PRIMARY KEY IN YOUR TABLE AND IT WILL HAVE A DEFAULT VALUE BASED ON THE CLIENT. SO  IT'S NOT SHOWING YOU THE CREATE NEW ENTRIES OPTION.
    SO TRY TO PUT ONE MORE FIELD AS THE PRIMARY KEY SO THAT YOUR PROBLEM WILL SOLVE VERY EASILY  ALSO MAKE SURE THAT TABLE IS ACTIVATED.
    REVERT IF U NEED SOME MORE HELP
    Thanks &Regards.
    Pavan.

Maybe you are looking for

  • Camera Raw loses system focus and becomes inactive

    While working in ACR if I hover over any of the command buttons, Save Image,  Open Image, Cancel, or Done for a few seconds the "tool tip" for the button displays and as soon as I move the mouse again the whole Camera Raw windows loses system focus a

  • How do I report a bug against Flash Player for Google Chrome?

    Flash Player for Google Chrome is currently developed jointly between Adobe and Google.  Because of this relationship, we would like to encourage users that are encountering issues with Chrome's Flash Player to report bugs directly to the Chromium da

  • Can no longer import Word files into InDesign

    Hello, For many months I have been importing Word files into InDesign CS3 (Mac OSX 10.4.11) with no trouble, but I started having a problem yesterday. When importing a 17-page Word file with 16 footnotes, I got none of the text and only the footnote

  • Cannot load mail - iCloud

    I receive the above message when logging in to iCloud beta. At first it said my password was incorrect, so I reset it and now when I log in it says 'cannot load mail' Also, when trying to retrieve my mail via my iPhone running iOS 5 beta, it says tha

  • Solaris 10 Install Hangs at 15% on my HP DL 585?

    Solaris 10 Install Hangs at 15% on my HP DL 585 I have taken out all the additional extra cards so I am left with the basic box, it has been configured to run in Raid 1 so my four disks become two. I can still get it to bring up a shell and do other