[JPA-Newbie] -- JPA 2 for dynamic/custom entity types (database schemas)?

Dear forum members:
Still being new to JPA and having worked through the JPA2 spec as well as a good Apress book for learning the JPA concepts, I am currently wondering if my current, rather dynamic application scenario can be realized in JPA 2 in an easy way.
The simplified app scenario is like the following:
Suppose there should be a JEE6 web app that allows endusers to publish articles. There is a generic "Article" type with some common/default attributes such as
- author : String
- pubDatetime : String or own.DateTime
- title, subtitle, articleText : String
Additionally, a privileged group of endusers should be able to enhance this generic "Article" type by custom attributes during runtime (i.e., dynamically) and via a web interface. Additional attributes could be
- articleTopic : ArticleCategoryEnum
- rating : Float
- comments : List<String>
I guess the intention should be obvious and btw. not uncommon.
My remaining main question basically is:
* How could such a scenario be implemented in JPA 2 the best way?
Due to the topic's importance importance for me, I'd be very grateful for any help or other productive tips/hints.
Thank you very much in advance.
- Sebastien

See,
http://www.eclipse.org/forums/index.php?t=msg&th=205349&start=0&S=6619f8634cb716a45f2bdaf577719d00

Similar Messages

  • 3rd party integration: How to get XML Schema (.xsd) for a custom entity, to use with a mapper

    Is there an easy way to get the xml schema/DTD for a custom entity, specifically an .XSD file for that entity (which will then be used to create a map to be able to transform the fields of the entity to a 3rd-party message format)?
    So have a custom entity with lots and lots of fields. Each of the fields will map to a differently named field to match the schema of the 3rd party entity. A very common situation. Looking to use a tool like the Biztalk mapper or Altova's MapForce to generate
    an .xslt file to transform the downloaded entity (service.Retrieve with all columns) to the new format. (Will implement a typical VETR pattern.)
    Apparently with CRM 4 there was a call that provided this, but from 2011 has not been available. Working with a crm 2015 system.

    That will give a descriptor of the table and allow creation of an .XSD file, but it's really complex in terms of types, and the there's type conversion. It might be an easy way to get a schema, with the downside being it's hard to use that schema. 
    It seems easier to do a fetch of the record with all fields filled in using service.Retrieve, and then converting this to xml, using Microsoft's guidance leads to using https://msdn.microsoft.com/en-us/library/hh675409.aspx which will serialize the entity
    into XML with all the fields converted to type string, and with complex fields likewise converted to strings with additional information about the type. 
    Using this it's possible using an number of tools to create an easier to use .XSD file.
    However, it would seem most integrations of this type are using 3rd party CRM connectors. Perhaps this is why Microsoft hasn't provided anything direct (and took away what they did have in crm4.0 due to it generating a hard to use .XSD or due to letting
    their partners continue income streams from selling connectors").
    But without using 3rd party connectors, or following the still tedious method of generating .XSD (a useable .xsd), have not yet come up with an easy, automatic way to get an .XSD or to easily integrate with 3rd party message format.

  • How to set new role for new custom entity only

    I created a new custom entity, I want to create new role for it only.  So I created new role and set custom entity User role. But When I login the user with created role, it show now right to access CRM.
    Awen

    Are you trying to grant access so that users can use this custom entity but no other data at all?
    You will still have to include access to all sorts of bits of CRM just to make the user interface work - especially the things on the Business Management and Customization tabs of your security role. You also need to check these 6 settings:
    Special privileges in CRM Security Roles
    If this is the only security role you plan to give to your users, I would suggest you start from a standard role and remove access to other entities, rather than start from blank and work upwards.
    Hope this helps.
    Adam Vero, Microsoft Certified Trainer | Microsoft Community Contributor 2011
    UK CRM Guru Blog

  • Urgent Help need for ABAP Custom Process Types

    Hi Gurus,
    I have created a Custom Process Type for ABAP program which returns status (Success or Failure).
    I followed the below procedure to create a custom ABAP process type.
    In RSPC, I went to Settings -> Maintain process types
    I selected the ABAP process type and then selected the EDIT -> COPY AS and then in the process chain configuration screen, I gave a new name to the process type, changed the POSSIBLE EVENTS settings to "2 process ends "successful" or "failure" and saved the settings to confirm changes.
    Now I can see the new process type for ABAP program which returns the success or failure for the successors.
    Now, my question is, where do i write the logic for ABAP program ? how does the ABAP program returns the success or failure. Do I have to change the code in the method IF_RSPC_EXECUTE~EXECUTE to return success or failure.  Please make me clear where I can write the code? For example in my ABAP program, I am searching a table to find a specific value. If the value is not found, then the ABAP process type should return failure, if found should return success. How can I do this?
    Thanks in advance,
    Regards,
    aarthi
    [email protected]

    Hi,
       We have a similar problem. We have an ABAP program in a process chain that
    uses a custom process type with on success and on failure.
        If  the program is successful there is no problem. it will run the next process step.
        The problem is when the ABAP Program fails and even though the message class is E in our ABAP program it has a confirm popup message with a status change and asks "Save Status and Trigger Events if Appropriate".
         Once you enter Yes to continue it then continues to the next step in the program and is fine.I traced in debug where this status message is appearing. It is in CL_RSPC_LOG. There is a popup_to_confirm_step where it checks the e_status that is value J ( Framework Error upon completion). Then it submits the rspc_process_finish program to complete and call the on error process step.
         Has anyone else experienced this and is there any other documents out there to help me?
    Apologies if this is not very clear.
    Any assistance would be appreciated.
    Thanks
    Monica Mandia

  • Is there a 2GB file size limit on saving a custom format plugin for a custom file type?

    I have resolved issues on reading files > 2GB. Now when I save files >2GB, I get a popup that states there is a 2GB limit for plugins.
    I an using photoshop CS6 on a MAC OSX 10.9 with 16 GB RAM.
    The custom file type is what should be selected when the Save As Dialogue is visible. 
    I looked for a setting in the Photoshop preferences for Files & setting to PSB, but did not see one.
    I tried modifying values in the PiPL for formatmaxSize and PluginMaxSize, but the only values that the code will compile in with:
    32767 & 2147483647.
    I saw a posting in previous years that custom plugins were limited to 2 GB. 

    I would like to rephrase my question, now that I have worked a little more with my code.
    Is there a 2GB limit per channel and 4GB limit for total file size for a custom photoshop format plugin?

  • PO new pricing for selected custom condition types

    Hi Experts
    We have certain custom pricing conditions determined through condition records.
    Periodically these conditon records undergo changes (new rates maintained).
    We would like to have redetermination of new prices for the custom conditions for all the open POs.
    Is it possible to have this function for the conditons types which undergo changes.
    Thanks
    ramSiva

    Hi ;
    You can filter open PO's with a selection parameter WE01 in ME2N.
    After that , go to MEMASSPO tcode , copy open PO's. And, update conditions with header or item EKPO-EBELP or EKKO-KNUMV.
    Transformation :
    KONV-KNUMV = EKKO-KNUMV.
    KONV-KPOSN = EKPO-EBELP.
    Regards.
    M.Ozgur Unal

  • Created column not showing in the Document Library View for a Custom Content Type based on Document

    We have a custom content type based of Document Content Type. The OOTB "Created" column does not show up in the view as well as in the Site Settings -> Columns.
    But it shows up in the Display Form and Edit Form of the Item at the bottom "Created at " by " " and "Modified by" at by ""
    Would anyone know how to make this column appear as part of the view ?
    thanks,
    Harsh

    Hi,
    They should by default be possible to add to a view. The only reason they would disappear from the UI if someone has changed the attribute of the Field to hidden = true. You can verify that with PowerShell and if so you can use PowerShell to revert the setting
    to false.
    $w = Get-SPWeb http://dev13$f = $w.Fields.GetFieldByInternalName("Created")$f.Hidden$f.Hidden = $false$f.Update()

  • Error using Quick Create Form on custom entity

    Hello,
    I have a new relationship between opportunity and a custom entity. Now I want to use quick create form for my custom entity. Then from the opportunity form, I click on the "new" action inside the custom lookup field but nothing happens and I have
    a JavaScript error... The quick create form has no JS code. The contact quick create form works fine. And the quick create form for my custom entity works if you click on the Add button on the main ribbon... so I'm lost... I've tried also with Chrome and IE,
    same result. May be I'm doing something wrong...
    Any help will be very apreciated.
    Thank in advance to everybody.
    The error:
    <CrmScriptErrorReport>
      <ReportVersion>1.0</ReportVersion>
      <ScriptErrorDetails>
       <Message>Unable to get property 'getAttribute' of undefined or null reference</Message>
       <Line>16</Line>
       <URL>/_common/JsProvider.ashx?ids=1545465446-1759665639-1968334880-202661451-1025323794-1793205875-1547461133-1992083491-1000289424-159335543-1376927455-1030632819-1181113682-1314140682-1194605645-1039841082-513446117-1625018438-1460109179-1088147315-706656670-342519603-542820515-1946640899-1603536461-468302605-1405388298-1220618931-511599809-1264077421-1188909594-783705869-374257838-502328314-2050812538-512064351&ver=1313516505</URL>
       <PageURL>/main.aspx?etc=3&extraqs=%3fformid%3d5b6f6723-db6e-40f2-9ca5-b78678b1076b%26id%3d%257b4F3786B4-4C0E-E411-93F6-0050569D1A22%257d%26rof%3dtrue%26rskey%3d200436436%26setlastviewed%3dtrue%26theme%3dOutlook15White&pagemode=iframe&pagetype=entityrecord&rof=true&rskey=200436436</PageURL>
       <Function>anonymous($p0){var$v_0=this.getLookupSearchText();this.$2a_4($p0,this.$$d_$3n_4);var$v_1=this.get_$1G_4(),$v_2=$get($v_1),$v_3=$v_2.getAttribute("entityDisplayName"),$v_4=Mscrm.InlineEditUtilities.getLinkedDataObject($P_CRM($v_2)),$v_5=String.format("glob</Function>
       <CallStack>
        <Function>anonymous($p0){var$v_0=this.getLookupSearchText();this.$2a_4($p0,this.$$d_$3n_4);var$v_1=this.get_$1G_4(),$v_2=$get($v_1),$v_3=$v_2.getAttribute("entityDisplayName"),$v_4=Mscrm.InlineEditUtilities.getLinkedDataObject($P_CRM($v_2)),$v_5=String.format("globalqctimestamps_{0}",$v_1),$v_6=null;if(!IsNull($v_4)&&$v_5in$v_4)$v_6=$v_4[$v_5];var$v_7,$$t_A,$$t_B,$v_8=($$t_B=this.$2Y_4($$t_A={val:$v_7}),$v_7=$$t_A.val,$$t_B);Mscrm.GlobalQuickCreate.GlobalQuickCreateBehavior.launchGlobalQuickCreate(this.$1Z_4,$v_3,parseInt($v_2.getAttribute("entityTypeCode")),$v_6,$v_8,$v_7,$v_0)}</Function>
       </CallStack>
      </ScriptErrorDetails>
      <ClientInformation>
       <BrowserUserAgent>Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.2; WOW64; Trident/6.0; .NET4.0E; .NET4.0C; .NET CLR 3.5.30729; .NET CLR 2.0.50727; .NET CLR 3.0.30729)</BrowserUserAgent>
       <BrowserLanguage>en-US</BrowserLanguage>
       <SystemLanguage>es-ES</SystemLanguage>
       <UserLanguage>es-ES</UserLanguage>
       <ScreenResolution>1364x768</ScreenResolution>
       <ClientName>Web</ClientName>
       <ClientTime>2014-09-01T16:13:52</ClientTime>
      </ClientInformation>
      <ServerInformation>
        <OrgLanguage>3082</OrgLanguage>
        <OrgCulture>3082</OrgCulture>
        <UserLanguage>3082</UserLanguage>
        <UserCulture>3082</UserCulture>
        <OrgID>{8704CF11-2D0C-E411-93F6-0050569D1A22}</OrgID>
        <UserID>{3DDB30DE-B80C-E411-93F6-0050569D1A22}</UserID>
        <CRMVersion>6.1.0.581</CRMVersion>
      </ServerInformation>
    </CrmScriptErrorReport>
    Francisco

    It looks like product error message.
    If it's happening on production, You can suppress the error message. Settings -> Administration ->Privacy Preferences -> Select Never send error report to Microsoft
    Regards,
    Prabhu
    Prabhu G

  • Generic Object Services for Custom Object Type

    I would like some advice please. I am not an ABAP Developer but I would like to enable the generic object services for transaction PP01 for a custom object type.
    I have searched for information, which suggests that the object needs to be published using the function module SWU_OBJECT_PUBLISH so that it is available in the Business Object Repository. If this is correct, please could someone tell me (in simple terms) how I can do this (with the assistance of an ABAP developer)?
    My colleague did some debugging which seemed to suggest that in order for the generic object services to be available, the field OBJTYP needs to be populated in table T778O. Is this correct? If so, how should this be done?
    Your advice would be greatly appreciated.
    Regards
    Corinne

    Hi,
    i'm also looking for the solution you have asked for.
    if you know how to do it please reply me with the solution.
    Thanks,
    suresh

  • FM to create support message for custom process type other than 'SLFN'

    Hi All
    Is there any function module or BAPI which will create support message for the custom process type other than SLFN.
    BAPI_NOTIFICATION_CREATE is posting only for the process type 'SLFN'
    Thanks in advance
    Regards
    Ravi

    Any ideas?

  • Customs document type cannot be determined for external document Type F8

    Hello Experts
    Need help
    I am trying to transfer F8 to GTS 10.1 and getting following message in GTS  Transfer log for export:
    Customs document type cannot be determined for external document Type F8
    New implementation
    GTS 10.1 running with SP 12
    ECC side Plug-In settings are fine. BAdi is Active.(There is no document mapping for F8/CUSDEC as it is not required in 10.1)
    GTS side configurations are also fine. Checked several times by 4 sets of eyes!!
    (Include general settings configurations, Customs communication configurations:)
    (Defining technical medium, conditions/output parameters, defining messages for communication process,
    defining determination for activity sequence and control settings for communication process)
    Despite this I am not able to trnasfer F8 successfully
    Can someone throw some light on this issue please?
    Keshav Murthy
    [email protected]

    Hi Dhilipan
    Here we go..
    You asked me to check the following
    Please check following things
    1) Legal regulation is activated. - Yes Activated
    2) Process template assigned to the legal regulation - Yes Assigned
    3) Activity Sequence determination - Yes done
    4) Open the activity sequence in under Control settings for Communication processes and check if there is a document type assigned to it. Table- /SAPSLL/TLEPAF - Yes done.
    It is really puzzling.
    Thanks
    Keshav Murthy

  • Fpga: dynamic mode vs type def for FPGA ref

    What are the differences for dynamic mode and type def for FPGA referenece?  When should I use which?  Is there a scenerio when I should use neither?
    Kudos and Accepted as Solution are welcome!

    So, you can still create a Type Def of a Dynamic Interface Refnum... That sounds confusing I know. Basically, my design flow is generally as follows:
    Develop initial FPGA code.
    Create a Control or Type Def with the FPGA Interface control configured for my FPGA VI.
    Develop my host, and use the Type Def in all of my subVIs.
    If I need to edit my FPGA code, now I only have to update the control in the typedef to propagate my interface changes to all of my subVIs
    Basically, every project I do has a FPGA Reference typedef for use in my host VI.
    Attached, you can find a (incomplete) sample project of mine that does this.
    Cheers!
    TJ G
    Attachments:
    Sample Project.zip ‏233 KB

  • Dynamic Discover - Nav Types

    I've created a new DLL for my custom navigation type and placed it into Dynamic Discovery.
    During the page load, I can see in PT Spy that the DLL was loaded. However, when I go to the subportal manager, I can't choose my new nav type. Any ideas on what I might be missing?
    Is there someplace where you can speciify how many nav types to load on the nav types manager page?

    Did you add a new constant to com.plumtree.portalpages.common.uiparts.NavTypeConstants or otherwise give your navigation a unique ID and name? The INavTypes.GetID method and INavTypes.GetName method must return a unique ID and name, respectively.
    Hope this helps,
    Chris Bucchere | bdg | [email protected]| www.bucchere.com

  • Custom Process Types not working in SAP BPC 10.0

    Hi Experts,
    We have migrated from SAP BPC 7.5 NW to SAP BPC 10.0 NW.
    We have three Custom Process Types created in BPC 7.5NW using the super class CL_UJD_SIMPLE_ACTOR as super class.
    It has been made Obsolete and Final class in BPC 10.0NW and the Custom Process types are not running as expected.
    Can you please suggest if there is any alternative for using the existing custom process types? Or do we have any alternative for creating custom process types?
    *Note: We have tried replacing the superclass with CL_UJD_ACTOR instead of CL_UJD_SIMPLE_ACTOR but of no use.
    Regards,
    Balraj.

    Hi Inl,
    The statement looks fine, just confirm:
    Your CATEGORY dimension is named CATEGORY? Is it really has property COMPARISOIN?
    Can you show the screenshot of UJKT run of script?
    What is your core BPC SP?
    Vadim

  • Required field in custom content type not required in custom list instance

    I have an issue with a custom SharePoint 2013 solution. Among other components, it consists of:
    a feature with several custom fields with different types, some of which are taxonomy fields,
    a feature with three custom content types using different sets of the custom fields with partially different configuration, e.g. whether they are required or not,
    a feature with a custom document library template and instance using two of the custom content types and a default picture library that is programmatically customized when the feature is activated, e.g. it is assigned the third custom content type.
    When deploying the solution and activating the feature, everything is set up correctly except a single taxonomy field for one of the doc lib's content types. It is defined to be required in both content types but indeed it does not show up as required for
    the default content type whereas everything works fine for the other. And it does not matter which of the two custom content types is defined first (= default) in the list template's schema.xml, the issue always occurs for the same taxonomy field in the doc
    lib's default content type. When I use the built-in Document content type as default, the field is required for both custom content types. However, using the Document content type is not an option.
    If you think this behavior is not strange enough: When the list content type's field is set required through the SharePoint UI, it becomes optional again when the list column is updated, e.g. its display name is changed.
    Any ideas?

    Hi,
    Thank you for your question.
    We are currently looking into this issue and will give you an update as soon as possible.
    Thank you for your understanding and support.
    Linda Li                
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Linda Li
    TechNet Community Support

Maybe you are looking for