How to add new CMP field to CMP bean

I am back for your amusement. I have seen similar things to this in other postings, but I have not been able to find one that, when action is taken, solves my problem.
I am using Sun Java Studio Enterprise 7 2004Q4
Our database changed by adding one new field. I need to update the bean for that table. Since the bean was created from a schema, I thought I need to update the schema first. Having found no way to do that yet, I recreated the schema under a different name, deleted the old one and renamed the new one to the old name. Follow that? :|
Ok. So now I have a new schema with the old name. I still have the old one in CVS so I can get it back (see I am learning someting).
I then went to the bean and added a new CMP field. I updated all my code to use the new field accessors. Changed the create method to have one more field and use the accessor.
Then in the module where the bean is being used I mapped the new field to the field in the database. The CMP is in a relationship with two other beans, but this field is not used (not yet anyway).
I then compiled and depoyed. Everything went ok. "I am really getting the hang of this EJB stuff", I said to my self. Then I tried to run it.... I should have saved the comment for another time... :(
I got this message and exception :
"Validation error in class com.PersonCMPBean685435892_JDOState: com.sun.jdo.api.persistence.model.util.ModelValidationException: Warning: Cannot find the column person.p_umd_id for mapping the field pUmdId in the class com.PersonCMPBean685435892_JDOState.
Verify that the schema file exists and that its contents are correct."
com.sun.jdo.api.persistence.support.JDOUserException: The mapping for class com.PersonCMPBean685435892_JDOState is invalid. Compile the class in the IDE, correct any errors, and verify that all required files are packaged for execution.
The schema exists. The field is in the new schema. Hmmm. I screwed up. Stamp it on my forehead with the others from working with EJB.... :)
So what did I do wrong? How is this supposed to be done. Is there an easier way to update the schema?
Any help will be greatly appreciated. Thank you.

Ok. I found something that works, albeit I don't think it is the recommended way. But since I can't find a recommended way, I will settle for working. This was a suggestion from someone else who had this problem ( http://swforum.sun.com/jive/thread.jspa?forumID=122&threadID=23428 ). But I have broken it down into steps and refined it a bit.
1. Create a new schema under a different name.
2. Go to the module that has a bean that is using the old schema.
3. Find the reference for the bean under the module and look at the properties for the bean.
4. In the properties in the Sun Java System As section there is a property called Mapped Schema. Change it to the new schema.
5. deploy
There's more...
If you need to have the same name for the schema, like I did because I keep it in CVS, do this:
6. Shutdown the IDE
7. Go to the directory where the schema is and rename it to whatever you need (whatever you had originally).
8. restart the IDE
9. repeat steps 2-4
10. restart the IDE again before you deploy!
I know this is insane. But it is all I could figure out so far. If anybody has something else that is better, please, please, please let me know!

Similar Messages

  • How to add new text field in standard report

    how to add new text field in standard report?

    Hi,
    I presume you are talking about a report display in ALV and u wish to add a column to it .
    If it is a global requirement ,as in table being used there in ALV can be modified, then you can append the table and the system should pick up the same automatically from there.
    Otherwise , you can make a Z program . Modify the catalog being used in ALV.
    Regards,
    Shweta

  • How to add new customise field in standard SAP ME28 Report?

    Hi Anybody,
             How to add new customise field inside Standard SAP Screen report ME28?.
    Anybody, Please tell me how to do?.
    Thanks,
    Regards,
    S.Muthu.

    Hi Subramaniyam,
    You can find enhancement in me28 by following steps and then apply your logic in include of this enhancement.
    cmod>Give a project name>in enhancement column give the package name ME >f4>in package write ME-->ENTER>It will show you all enhancements available in me28> find which ever suits your requirement>save > click on components> from there you can make changes in include program.to add that particular field.

  • How to add new subscreen & fields to ME51N

    Hi Experts,
    How to add new subscreen and to add new fields at item level, maybe someone have done this before and maybe can guide me...
    Thank You.

    someone have experience on this? so can you guide me... tq

  • How to add new "text" field in GL item fast entry?

    Hi Gurus,
    Is that possible to add "text" column or field in GL item fast entry. For example, if i go to Txn F-04, i enter all the details then i go to: "Goto>GL item fast entry (shift+F8). Now you will see layout (GL item fast entry). So back to my question before, is that possible to add new field or column (text field) in this layout? If the answer is Yes, appreciate Gurus help and guide me in configuration, if any.
    Thank you
    Regards,
    Nazrul

    Hi Sreehari Annavaram,
    Thank you for your kind reply. Based on the answer from the link you have given me (as per below quote), there's no "DEM03" in my selection screen. We only have SAP01, SAP02 and GL001 (customised layout). That's why i had created new customised layout GL002 and try to add the "text" field in layout as per my first question. But system still won't allow it.
    *"In F-02 under editing option screen screen templates and line layout variant for document entry will be there in that
    GL accounts items for fast entry select DEM03 u will get the text item"*
    Appreciate help.
    Thank you
    Regards,
    Nazrul

  • How to adde New Language field value in CRM Business Partner Language Field

    Dear all,
    How can we add a new field value to the Business Partner Language field in CRM and ECC systems.
    Your suggestions will be highly appreciated
    Thanks
    Sravanthi

    Hi Shravanthi,
    You would need to add the new language to table T002. Once this is done, it will appear in the drop down menus.
    Regards,
    Rishu.

  • How to add new additional field in my selection screen?

    Hi,
    In the BEx ,I have key and name in my report.While seeing the report, heading for  customer number is coming and heading not coming for customer description.I need to have it in my report.
    I.e
    Customer     !     (This heading is missing)
       7     GABRIEL CHEMIE GMBH - AUSTRIA
       9     BERGER PAINTS BANGLADESH LTD.
    Any tips?  Points will be given.
    Regards,Jaheer

    Hi Jaheer ,
                     If you talking Abuot heading in out put screen then use TOP-OF-PAGE
    or Else you use "Write:/ " Statement in you program...So that when first line is complete it will go to next line...
    What I understand from your Question....
    Souman

  • How to add new fields in collaboration tasks?

    Hi experts,
    Currently, by default, we are able to see in the collaboration tasks rooms fields as "Subject", "From", "Sent Date" , "Due Date" ,
    "Status"...
    Now i want to add new custom fields apart from standard; when i create new tasks i want fill this new fields and after, display this fields in the UWL.
    Can you please let me know how to add our own fields in the collaborations tasks rooms ?
    Thanks in advance,
    Regards,

    Hi Victor Capi,
    Could you have a look at the following link.        
    http://wiki.sdn.sap.com/wiki/display/KMC/XMLFormBuilderinEP7.0
    Formsbuilder open the collaboration project and you add the fields. Then import the xml to your portal.
    Regards,
    Prabha

  • How to add new fields in Reduced message ( in BD53 )

    Hi Experts,
    How to add new fields in Reduced message ( in BD53 ), when the required field iis available in Table or Structure and need to be added in BD53 so that we can ALE.
    Thanks,
    Ninad

    Hello,
    I think of something like:
    First, you create extension, with transaction WE30.
    Then, reduce your idoc, your extension should also be proposed.
    Do not forget to add this extension in outbound we82, and/or we57 in inbound, and WE20, and find BTE or exit to populate extension.
    regards.
    F.S.

  • PLz Help me its urgent, how to add new field in mm01 basic data screen

    Hi everyone,
         plz tell me how to add new field in mm01 basic data screen,i added that field in basic data screen but when i create a material the data for that field will not save in database table.
    Thanks,
    murali.

    Hi Murali,
    when created added a field on the screen by using user exit then after that you have add the field in main table where you will be getting these table in the userexit only, please make sure about this. And i am sure defenitly it will get updated in to the table.
    reward if useful.
    thanks
    abdulsamee.

  • How to add New field in SMART forms.

    How to add new field in the SMART FORMS. Please know me the step.
    Please help me soon.
    Moderator message: Welcome to SCN!
    Moderator message: please search for available information/documentation, do not use a priority higher than normal (no "soon", "ASAP", "earliest" etc.).
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers]
    Edited by: Thomas Zloch on Jun 17, 2011 12:31 PM

    How to add new field in the SMART FORMS. Please know me the step.
    Please help me soon.
    Moderator message: Welcome to SCN!
    Moderator message: please search for available information/documentation, do not use a priority higher than normal (no "soon", "ASAP", "earliest" etc.).
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    [Asking Good Questions in the Forums to get Good Answers|/people/rob.burbank/blog/2010/05/12/asking-good-questions-in-the-forums-to-get-good-answers]
    Edited by: Thomas Zloch on Jun 17, 2011 12:31 PM

  • 11.5.9/OAF 5.7 : how to add new fields in iProc "search results" page

    We need to add new fields into iProc "search results" page - "Personalize Self-Service Defn" is et, we can enter the personalization screens (from both the "master" link at top/right page level or from the link above the region) - anyway cannot find how to add new fields. Do we have to go to AK developer and/or XML files or is it feasable from OAF (as it is with 11510) ? TIA.

    It depends on what fields you want to add.
    1. If Oracle has included the fields, just render them via personalizations
    2. If they are brand new fields:
    a) you will need to extend the VO (I do not know the exact name).
    b) change the query to get your extra db columns if necesary
    c) add transient attributes to the VO and map them to b).
    d) Then you need to add the items via personalization and map them to the attributes you created in c)
    Check on metalink for the lates version of OAF Dev Guide and Personalization guide.
    Thanks
    Sandeep

  • Query: How to add new fields in ABAP query?

    Hi All,
    Can any one tell me how to add new fields in the ABAP query output?
    We have to add the new fields using query design or we have
    to add those in the background program(automatically generated behind query) by selecting new fields in the code?

    What kind of report? Usually, you have to add the field in the table declaration and then also in the SQL query. After that, include the field in what kind of report you are using.

  • CRM  IC Winclient - How to add new fields in the BP Search of TRX CIC0

    Hello Experts,
    I want to know how to add new fields in the BP Search of TRX CIC0. In the HTML that we're using here I need to add the URL of the BP.
    Can you help me?
    Thanks in advance.
    Caíque Escaler

    Hi
    make append to tables in se11 - CCMBP1FIELDS, CCMBP2FIELDS
    in spro in Define customer-specific search control -> mark fields with X.
    and enhance html template CRM_CIC_SEARCH_DISPLAY. -> tcode smw0, look for package CRM_CIC_COMPONENTS for html CRM_CIC_SEARCH_DISPLAY. export it from SAP, edit, and import.
    you will need to enhance function module used for searching - you will find him in spro in Search Strategies.
    Regards
    Radek

  • How to add new fields to picklist of search criteria for opportunities

    Hi Friends,
    Could you please tell me how to add new fields to the picklist of search criteria of Opportunities in WEBCLIENT(CRM 2007).
    Regards,
    Vijay

    Dear Vijay,
    We are facing the same problem over here.
    Have you managed to find a solution? Please share
    BR,
    Rohit

Maybe you are looking for

  • Problem with traverse method

    Hi, I am having this problem: I made a CustomItem, a TextField, now I overloaded the traverse method, so if the keycode is Canvas.UP or Canvas.DOWN then return false else return true. The problem is that when I press the left or rigth button it also

  • Best way to aggregate large data

    Hi, We load actual numbers and run aggregation monthly. The data file grew from 400k lines to 1.4 million lines. The aggregation time grew proportionately and it takes now 9 hours. It will continue growing. We are looking for a better way to aggregat

  • Can I replace the LCD with an LED on Early 2009 24" model?

    I have an old 2009 (okay, so not that old) iMac and the LCD has some serious burn-in and it's to the point where I can't use the computer without it hurting my eyes. I'm looking to replace the screen, but the computer still works great and I don't wa

  • May i know how to create Transactional Infocube, Data from cube to cube

    Hi All, I need to create a Transactional Infocube. Can anyone help me how to create that. and how it differs from Basic cube while creating Transactional Infocube. My other question is how to load data from one cube to another.( is it possible from b

  • CR2008 SP2 and VS2008 Report Viewer Error

    Upgraded to CR2008 SP2 since my previous version of CR did not integrate with VS2008.  Finally go all the merge modules cleaned up but now my report simply will not load in the viewer.  In debug mode everthing run fine until I try to load the report