Add a new aprtition to existing table

Hi all,
we have already a table badge2 in our database we need to add partition but when we add this like we get some errors. below is the structure of the table .please any one suggest me how do i add a partition to existing table. quick response will be higly appreciated.
Name Null? Type
EMP_TYPENO NUMBER(10)
EMP_NO NUMBER(10)
EMP_DATE DATE
EMP_TIME DATE
EMP_EVINT NUMBER(1)
EMP_FLAGE NUMBER(1)
MAC VARCHAR2(50)
EMP_CARDNO NUMBER(3)
when i run these queries it give errors like this
sql> alter table badge2 partition by range (emp_date)
add partition p1 values less than (TO_DATE('01/01/2005', 'DD/MM/YYYY')));
ERROR at line 1:
ORA-01735: invalid ALTER TABLE option
or
sql> alter table badge2 partition by range (emp_date)
partition p1 values less than (TO_DATE('01/01/2005', 'DD/MM/YYYY')));
ERROR at line 1:
ORA-01735: invalid ALTER TABLE option
or
SQL> alter table badge2
add partition p1 values less than (TO_DATE('01/01/2004', 'DD/MM/YYYY'));
alter table badge2
ERROR at line 1:
ORA-14501: object is not partitioned
BEST REGARDS

Hi,
You can only add partitions to a partitioned table. When the table is non-partitioned table you will be greeted with an error as shown below:
SQL> create table t(dt date);
Table created.
SQL> alter table t add partition  p1 values less than (TO_DATE('01/01/2004', 'DD/MM/YYYY'));
alter table t add partition  p1 values less than (TO_DATE('01/01/2004', 'DD/MM/YYYY'))
ERROR at line 1:
ORA-14501: object is not partitionedIf the table is already partitioned then you can add partitions as shown below:
SQL> create table t1( dt date) partition by range(dt)
  2  (partition p1 values less than (TO_DATE('01/01/2004', 'DD/MM/YYYY')));
Table created.
SQL> alter table t1 add partition p2 values less than (TO_DATE('01/02/2004', 'DD/MM/YYYY'));
Table altered.
SQL>I would suggest you to read this document for a clear understanding on how partition are created and maintained:
http://download.oracle.com/docs/cd/E11882_01/server.112/e10713/schemaob.htm#CFAGCHCD
http://download.oracle.com/docs/cd/B19306_01/server.102/b14220/partconc.htm#sthref2570
http://download.oracle.com/docs/cd/B19306_01/server.102/b14231/partiti.htm#i1108745
Regards
Asif Momen
http://momendba.blogspot.com

Similar Messages

  • Add a new field to existing Table

    Hi , We want to add a new field to existing table from ECC  and populate historical data .
    We have already extracted data from ECC to VBAK Table . We have to add a new field - Incoterms in HANA . This field exists in ECC .
    Please guide.

    Hi Vicky,
        I dont think you can add new fields to the condition table once you have activated the condition table.
    SAP says you can only make limited changes to the condition table, like changing the description, fast entry screen, header and footer fields, but not able to add new fields to the table, and I think that is the correct approch or else for the same table you will have two sets of condition records.
    Please refer to the below link:
    http://help.sap.com/saphelp_erp60_sp/helpdata/en/de/7a8534c960a134e10000009b38f83b/frameset.htm
    What you can do is create a new condition table with additional field and assign this table before the currently used table in the access sequence.
    Hope this helps.
    Regards
    Raj

  • How to add a new system in existing 3 system lanscape in stms

    Hi,
    we have 3 system in our STMS i.e Dev->Qua->Prod. now we have install one more quality system for business requirement and add the same saystem in stms.
    now my query is that how we can add this new system in existing transport route so that transport request can be added automatically to import queue of both quality system once released from development system.

    Hi Nadar,
    It is possible, But not recommended. Better if you have solution like...
    DEV-->QAS1-->QAS2-->PRD
    But it is possible by using transport groups. There are lots of posts aleady regarding this.
    Basis Stms Configuration Notes
    http://sap.ittoolbox.com/groups/technical-functional/sap-basis/4-system-landscape-stms-2712918
    4-system landscape
    STMS config for dual prod (w/ auto synch)
    Thanks
    Asad

  • Can't add a new column to LCD table? Option there, just wont add it.

    I have a LCD form with a table in it. Im trying to simply add a new column to the table. The option is there but the column just wont appear after clicking add Column to Left. I selected a column, right clicked the space > Insert > Column to left. But wont intsert. The table object properties tab shows rows and colum numbers but they are grayed out.
    See screenshots:
    http://www.emermed.net/staging/forums...
    http://www.emermed.net/staging/forums...
    This is a dynamic table where a new row can be inserted using a button. Is that dynamic nature the issue? Id hate to undo all the dynamic flow and programming just to add a column then reapply everything.
    Thanks!

    Hi,
    You don't add columns in the Object > Table palette (Screenshot 2). I suspect that the problem is that there is not enough on the page (within the content area) to actually add the column. In Screenshot 1, if you look at the width of the highlighted column versus the space available to the right of the table, you will see that a column cannot be added due to space restrictions.
    Reduce the width of the highlighted column (temporarily), then add a column. Once added, you can resize the columns to match the page width.
    Hope that helps,
    Niall

  • Can I add a New Folder to existing Business Area with Command Line?

    Hi,
    Can I add a New Folder to existing Business Area with Command Line in Discoverer (java or executable)? I am trying to do this with /load...
    /connect walkep_apps/walkep@smpdev1
    /load Visualizations /eul walkep_apps /user smp_naps_apps /object VISUAL_20K /capitalize /remove_prefix /insert_blanks
    /aggregate DETAIL /show_progress
    ... but this creates a new business area, "Visualizations 1", which is not what we want! We want to add the VISUAL_20K to the existing "Visualizations" business area. Many thanks in advance.
    Phil

    Bang on. thanks
    three's always an obvious solution.
    I'll post another question about how to attached a file into a Mail message which is automatically compressed/zipped. Or do i have to find the file in Finder, compress it and then attached it?

  • I am new in DART extract and  wanted add the new field in Existing Segement

    Hi ALL
    I am new in DART extract and client is request us to add the new field in Existing Segment.
    What is proceedure i need to follow to add the new field in existing segment.
    Moderator: Please, post in proper forum

    I added an Interactions button and in the Actions on Success I open an URL or file. I have placed the video on our web server.   In the URL I point to our web server "http://www.wmabhs.org/Media/Add Client 3rd Party Coverage.mp4".  If I run this from any browser it works.  So what do you think I have done wrong?

  • HT2486 Can I add a new contact to existing business card without re-entering all business data?

    Can I add a new contact to existing business card without re-entering all business address info?

    Bang on. thanks
    three's always an obvious solution.
    I'll post another question about how to attached a file into a Mail message which is automatically compressed/zipped. Or do i have to find the file in Finder, compress it and then attached it?

  • Add a new field(from transparent table) to the infoset

    Hi,
    I need to add a new field to the existing infoset in HR. I found that field exist in the CSKS table. in the infoset they are using PNP logical database. As per my understaning i have to link the CSKS-KOSTL with P0001-KOSTL.
    Could you tell me how to do this?
    Please do the needful.
    Thanks & Regards,
    Krishna.

    Hi,
    I have added that KOSAR in the additional fields and i added the code for that like
    clear kosar.
    select single kosar
      into kosar
      from csks
      where kokrs = p0001-kokrs
        and kostl = p0001-kostl.
    Is it will work now? One more help how to add this change to the transport?
    Please do the needful.
    Thanks & Regards,
    Krishna.

  • Best approach to publish new table or new column on existing table on MDW?

    Hi,
    I'm refering to Olite R3 without any patches. I don't use Java API, I use MDW.
    if I have a new table or a new column on a existing table, what's the best approach to publish it?
    I'm asking this because I've trying lots of approaches and the only solution was, step-by-step:
    1) On MDW, drop the publication item
    2) Add again the publication item
    3) Associate the publication item to the publication
    4) Save everything
    5) File / Deploy (if I don't do it, it does not work)
    6) Tools/Package... (that's where it's a problem: if I don't remove the app and create it again it does not work!)
    7) on the client side, I perform a msync with "force refresh"
    That's the only way I found to publish new items for sure. Any other action does not push the new table or new column to the client's embbeded DB.
    Any comments?
    Regards,
    Maurício Américo Vernaschi.

    I do not use MDW, rather a mix of java and the final publish step you use, but
    Adding new PIs should be easy, just add them and re-publish (no need to drop anything)
    for changes, if you just have new columns and the sql statement is 'select * from' then you should just need to make the changes in the base schema objects, and run the publish with no changes and the updates should be picked up. If selecting specific columns, then update and re-publish.
    When using MDW at the end you can save the application as a jar file, and then use this jar file to publish in the mobile manager - this is the best wayto publish.
    Have a look at this jar file in winzip, and you will find it contains a web.xml file. This is the xml definition of the publication items, and for simple changes it is possible to just edit this file and republish via the mobile manager

  • How to add a new field at a table controll screen change for CIN 2007????

    HII EXPERTS
    I HAVE TO CHANGE THE SCREEN OF J1IA TCODE . I HAVE TO ADD A  NEW FIELD IN THE SCREEN LAYOUT OF TCODE J1IA TABLE CONTROLL.
    THANK YOU IN ADVANCE,
    PLZ HELP ME OUT AS IT IS VERY URGENT.
    SUPRATIK

    Hi Supratik,
                     you can do it by looping at screen structure and append field
    dynamically.
    see help on  'screen' structure.u will get ur requirement.
    Rewards points if helpful.
    Regards,
    Hemant

  • Cannot add a new server in existing server pool

    Hi,
    I am trying to add a new server into an existing server pool.
    I have the same agent password, the same root password (i don't think is important).
    It disovers the server and is on unassigned Servers.
    When trying to add into existing server pool it fail with:
    Job Internal Error (Operation)com.oracle.ovm.mgr.api.exception.FailedOperationException: OVMAPI_4010E Attempt to send command: dispatch to server: vmsibm2 failed. OVMAPI_4004E Server Failed Command: dispatch https://?uname?:[email protected]:8899/api/2 configure_server_for_cluster lun /dev/mapper/35000144f85151729 0004fb0000050000c696b251dc81a087 , Status: org.apache.xmlrpc.XmlRpcException: exceptions.OSError:[Errno 2] No such file or directory
    Any ideeas?
    Regards
    Nicolae

    Hi,
    I can see your point...
    From my error :Server Failed Command: dispatch https://?uname?:[email protected]:8899/api/2 configure_server_for_cluster lun /dev/mapper/35000144f85151729 0004fb0000050000c696b251dc81a087 , Status: org.apache.xmlrpc.XmlRpcException: exceptions.OSError:[Errno 2] No such file or directory
    /dev/mapper/35000144f85151729 is the path where the server pool uses for it's own...
    and
    0004fb0000050000c696b251dc81a087 is the Pool file System...
    On storage menu, at SAN Servers - Unmanaged iSCSI Storage Array - where I see my storage wich is with iSCSI at Add/Remove Admin Servers I added this new server.
    Also I went to Rescan Physical Discks for my new server.
    When I go with putty on my server and run
    df -h
    I don't see any storage...
    I belive I missed one step but I can't find wich one...
    Regards
    Nicolae

  • Add a new field in custom table but not show on SM30

    I add a new field in a custom table, did Table Maintenance generator and SE93.  But that field did not show on SM30 screen.  How to make it show on the SM30?
    Thanks
    Helen

    Hi,
    I think its the Problem with TMG.
    Go to TMG screen delete the old TMG and regenerate the new TMG
    Hope it helps
    regards
    Prasanth

  • Add a new column in search table SERIAL_NUMBER that remains 1-10 everytime

    Hi All,
    I need to add a column SERIAL_NUMBER to search table and what i want is that it should display 1-10 on every page.I press Next and it should again show Sr No. 1-10.
    For this i added a transient variable to the SearchVO and the CO code for Table region is as follows :-
    public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
    super.processFormRequest(pageContext, webBean);
    SearchAMImpl am= (SearchAMImpl)pageContext.getApplicationModule(webBean);
    SearchVoExImpl vo=(SearchVoExImpl)am.getSearchVoEx();
    SearchVoExRowImpl searchRow=(SearchVoExRowImpl)vo.first();
    searchRow.setSerial(new Integer(1));
    while(vo.hasNext())
    if(searchRow.getSerial().intValue()==11)
    searchRow.setSerial(new Integer(1));
    int i=searchRow.getSerial().intValue();
    Integer p=new Integer(i+1);
    searchRow=(SearchVoExRowImpl)vo.next();
    searchRow.setSerial(p);
    The problem i am facing with this is when i sort the result table using any column the Serial Number gets disappeared.
    And also when i press Go button for searching it shows me the end results first.
    Please help me out.

    hi,
    yes i am displaying 10 rows at a time and also there is no order by clause in VO query.
    The above method did not work again. I tried and again got the serial number which is not ordered.
    You can see my query:- select decode(mod(rownum,10), 0, 10, mod(rownum,10)) Serial_Number,party_name,address1,address2 from hz_parties
    As i mentioned in my question in the beginning that after sortin the sr_no disappers i am able to solve it by handling SORT_EVENT.
    Now the only problem left is that it shows me the last results first. Can you please help me here?
    Thanks

  • Add a new column in item table control of va01 screen

    Hi All,
    i have requirement to add new column in item table control of va01 screen 4900 for the custome field of vbap table
    the required coloum is add with the help of access key
    however whem i am trying to save data, that custom field is not populate
    please let me know if any one had work on this

    I think i solved the problem . The single way to to that is to modify the SAP standard Screen.

  • How can I add a new background to existing photo?

    Hi folks!
    I got Adobe elemets 8 new and I was trying the whole day now to add a new background to an existing photo.
    There is one main photo showing a face of a man and I would like to cut that face out and plant it into another photo to use the background !
    OR leave the face as is  and upload a new photo to set it as a background.
    However I cannot find an upload function at all.
    Hope it makes sense what I am trying to describe here.
    Also - any answers in german language would be awesome (OR if english: please keep it simple). 
    Thanks a lot!!!
    Angi

    I hope this video will be able to help you:
    http://www.youtube.com/watch?v=4XGKbIaqcRQ
    This is just a basic example. If you have any specific query, please post again, and I am sure there are many experts around here, who will help you.
    Regards,
    Ankush

Maybe you are looking for