https://raw.githubusercontent.com/ajmaradiaga/feeds/main/scmt/topics/ABAP-RESTful-Application-Programming-Model-qa.xml SAP Community - ABAP RESTful Application Programming Model 2024-07-27T14:00:08.391973+00:00 python-feedgen ABAP RESTful Application Programming Model Q&A in SAP Community https://community.sap.com/t5/technology-q-a/resource-not-found-for-segment-xxxxxx/qaq-p/13760272 Resource not found for segment 'XXXXXX' 2024-07-14T20:07:27.680000+02:00 Bharath_Ramireddy https://community.sap.com/t5/user/viewprofilepage/user-id/1475193 <P>Hi, I am getting this error in SAP gateway Resource not found for Segment 'XXXXXX' when clicking on a Fiori app to get data.<BR /><BR />I am working on a Fiori app getting data in sap gateway for that entity set but in Fiori app getting error mentioned above.<BR />Tried cleaning up cache and loading metadata and regenerating the project in <SPAN>SAP Gateway Service Builder (SEGW).<BR />I'm getting data in sap gateway for that entity but not in the Fiori app.<BR />Can anyone let me know how I can fix this error?<BR /><BR />Thanks in advance.</SPAN></P> 2024-07-14T20:07:27.680000+02:00 https://community.sap.com/t5/technology-q-a/how-to-avoid-empty-drafts-in-rap/qaq-p/13760657 How to avoid empty drafts in RAP? 2024-07-15T10:06:29.091000+02:00 Bohdan https://community.sap.com/t5/user/viewprofilepage/user-id/180051 <P>Hi Experts,&nbsp;</P><P>I'm experimenting with RAP-model. I've implemented a sample RAP BO (managed implementation), where I try to create custom rules in a Z-table. I have two tables: persistent table &amp; a draft table. So far, everything works fine - drafts are being created / updated in the draft table and upon saving the content is properly moved to a persistent table. I've also implemented a custom logic to validate the semantic key and it also works fine.</P><P>My only concern is that when I hit the "Create" button and immediately leave the processing, the RAP is generating an empty entry in the draft table. This entry does not have any data except a couple of standard fields e.g. created_at, created_by, local_last_changed etc.</P><P>So my question is: is it possible to implement any logic that would prevent creation of drafts if they have no data ?&nbsp;</P><P>Regards,</P><P>Bohdan</P> 2024-07-15T10:06:29.091000+02:00 https://community.sap.com/t5/enterprise-resource-planning-q-a/is-it-possible-to-quot-consume-quot-metadata-extensions-in-sapui5/qaq-p/13760883 Is it possible to "consume" metadata extensions in SAPUI5 2024-07-15T13:10:55.479000+02:00 vulturas https://community.sap.com/t5/user/viewprofilepage/user-id/39573 <P>Hello everyone,</P><P>I learn ABAP RAP and have defined a metadata extension in my service.</P><P>&nbsp;</P><pre class="lia-code-sample language-abap"><code>@Metadata.layer: #CORE @UI.headerInfo: { typeName: 'Handling Unit', title: { value: 'HandlingUnitNumber', type: #STANDARD }, description: { value: 'HandlingUnitUsageDescription' } } annotate entity /#####/##### with { .facet: [{ id: 'HeaderFacet', purpose: #HEADER, type: #FIELDGROUP_REFERENCE, targetQualifier: 'HeaderItems' }] .fieldGroup: [{ qualifier: 'HeaderItems', position: 10 }] PackagingMaterialName; }</code></pre><P>&nbsp;</P><P>Is it possible to use/call/consume this metadata extension inside a SAPUI5 app as an addition? I read something about extensions points, but they didn't help me much <span class="lia-unicode-emoji" title=":confused_face:">😕</span></P><P>&nbsp;</P><P>Any approach or hint is appreciated.&nbsp;</P><P>&nbsp;</P><P>Kind regards</P><P>Jürgen</P> 2024-07-15T13:10:55.479000+02:00 https://community.sap.com/t5/technology-q-a/behavior-validation-messages-are-not-displayed/qaq-p/13761252 Behavior validation messages are not displayed 2024-07-15T17:18:38.053000+02:00 PatrickAngevare https://community.sap.com/t5/user/viewprofilepage/user-id/162234 <P>Validation error messages in a behavior implementation are not displayed and elements are not highlighted.&nbsp;</P><P>In the behavior implementation for a draft enabled RAP based Fiori Elements application there is a custom check for mandatory fields. If a mandatory field is not filled, an error message should be displayed and the relevant element should be highlighted. The validation is executed correctly and the save action is stopped but only a generic error message ("<SPAN>Resolve data inconsistencies to save changes.</SPAN>") is displayed and no field is highlighted. When the app runs in preview mode via the Service Binding in Eclipse, the validation messages are correctly displayed and the relevant fields highlighted. The issue only occurs if the app runs in the Fiori Launchpad.</P><P>Behavior definition:&nbsp;</P><pre class="lia-code-sample language-abap"><code>managed implementation in class zbp_i_product unique; strict ( 2 ); with draft; define behavior for ZI_Product alias product persistent table za_product draft table zd_product authorization master ( instance ) lock master total etag LastChangedAt etag master LastChangedAt { create; update; delete; field ( mandatory ) ProductName; field ( readonly, numbering : managed ) ProductUuid; field ( readonly ) CreatedBy, CreatedAt, LastChangedBy, LastChangedAt; validation validateMandatoryFields on save { field ProductName create; } mapping for za_product { ProductUuid = product_uuid; ProductName = product_name; ProductType = product_type; CreatedBy = created_by; CreatedAt = created_at; LastChangedBy = last_changed_by; LastChangedAt = last_changed_at; } draft determine action Prepare { validation validateMandatoryFields; } draft action Edit; draft action Activate optimized; draft action Discard; draft action Resume; }</code></pre><P>Behavior implementation:&nbsp;</P><pre class="lia-code-sample language-abap"><code>CLASS lhc_product DEFINITION INHERITING FROM cl_abap_behavior_handler. PRIVATE SECTION. METHODS validatemandatoryfields FOR VALIDATE ON SAVE IMPORTING keys FOR product~validatemandatoryfields. ENDCLASS. CLASS lhc_product IMPLEMENTATION. METHOD validatemandatoryfields. READ ENTITIES OF /zi_product IN LOCAL MODE ENTITY product FIELDS ( ProductName ) WITH CORRESPONDING #( keys ) RESULT DATA(products). LOOP AT products ASSIGNING FIELD-SYMBOL(&lt;product&gt;). APPEND VALUE #( %tky = &lt;product&gt;-%tky %state_area = 'VALIDATE_MANDATORY' ) TO reported-product. IF &lt;product&gt;-ProductName IS INITIAL. APPEND VALUE #( %tky = &lt;product&gt;-%tky ) TO failed-product. APPEND VALUE #( %tky = &lt;product&gt;-%tky %state_area = 'VALIDATE_MANDATORY' %msg = new_message( id = `ZPRODUCT` number = 009 severity = if_abap_behv_message=&gt;severity-error ) %element-ProductName= if_abap_behv=&gt;mk-on ) TO reported-product. ENDIF. ENDLOOP. ENDMETHOD. ENDCLASS.</code></pre><P>The Fiori app is created as a Fiori Elements List Report based on an OData V4 service.&nbsp;</P><P>&nbsp;</P> 2024-07-15T17:18:38.053000+02:00 https://community.sap.com/t5/technology-q-a/deploying-app-using-abap-cds-annotations/qaq-p/13761749 Deploying App using ABAP CDS Annotations 2024-07-16T09:22:21.061000+02:00 nicknf https://community.sap.com/t5/user/viewprofilepage/user-id/1461814 <P>Hello,</P><P>I build an RAP-App using ABAP CDS including Annotations. I deployed the service with the service binding OData v4 - UI. There are a lot of tutorials showing how to generate a Fiori Elements Floorplans-based app using the service.</P><P>However, I was wondering what are the steps necessary to deploy this app in a productive environment to a Fiori launchpad? Is this document anywhere?</P><P>Thanks for your help</P> 2024-07-16T09:22:21.061000+02:00 https://community.sap.com/t5/technology-q-a/rap-default-value-managed-with-draft/qaq-p/13762014 RAP: Default Value (managed with draft) 2024-07-16T12:33:52.267000+02:00 lars_kr https://community.sap.com/t5/user/viewprofilepage/user-id/1450529 <P>Hello SAP Community,</P><P>What is the current best practice for specifying default values when creating an Object?</P><P>In my scenario, I have a managed RAP application with Draft.&nbsp;What I don't mean is giving default values about the possibility of a "determination ... with <SPAN>on save { create; }".</SPAN></P><P><SPAN>The values should already be in the editable input field when the object page is called up via the Create button. </SPAN></P><P><SPAN><A href="https://help.sap.com/docs/abap-cloud/abap-rap/operation-defaulting" target="_blank" rel="noopener noreferrer">Operation Defaulting</A>&nbsp;is not an option on OnPrem.&nbsp;I don't think this option is available there yet.</SPAN></P><P><SPAN>regards,</SPAN></P><P><SPAN>Lars</SPAN></P> 2024-07-16T12:33:52.267000+02:00 https://community.sap.com/t5/technology-q-a/ui5-input-value-dissappearing-after-selecting-from-value-help-dialog-using/qaq-p/13762380 UI5 Input Value Dissappearing After Selecting from Value Help Dialog Using OData V4 and RAP 2024-07-16T17:59:54.805000+02:00 ArianH https://community.sap.com/t5/user/viewprofilepage/user-id/1426676 <P>I'm developing a UI5 application that includes input fields with various value help dialogs. The application is a freestyle app utilizing an OData V4 service, which I built using CDS Views and the RESTful Application Programming (RAP) model. Consequently, I assumed that using&nbsp;<A href="https://sapui5.hana.ondemand.com/test-resources/sap/fe/core/fpmExplorer/index.html#/buildingBlocks/field/fieldEdit" target="_self" rel="nofollow noopener noreferrer">sap.fe.macros.Field</A> would be appropriate for this scenario.</P><P>The OData service reads from a table that contains one entry with empty fields, allowing me to use this service for value help binding.<BR /><BR /></P><P><STRONG>The Issue:<BR /></STRONG>When I select a value from the value help dialog, it briefly appears in the input field for about one second before disappearing. It seems like the fields are reloading and fetching empty values from the backend.</P><P>Has anyone encountered this issue before? How can I resolve it? Should I consider using different UI elements?<BR /><BR />Thank you for your help!</P> 2024-07-16T17:59:54.805000+02:00 https://community.sap.com/t5/technology-q-a/activate-draft-instance-on-post-call/qaq-p/13763660 Activate Draft instance on POST call 2024-07-17T18:03:52.797000+02:00 Shahab2 https://community.sap.com/t5/user/viewprofilepage/user-id/1476580 <P>Hi Everyone,</P><P>Have built a Managed RAP with draft mode. I am doing a POST service call with Payloads, and it should create entries under the Persistent Custom table. But the issue is it creates entries in Log table and sometimes it doesn't.</P><P>Have gone through link&nbsp;<A href="https://help.sap.com/docs/abap-cloud/abap-rap/preparing-draft-instances-for-activation" target="_blank" rel="noopener noreferrer">Preparing Draft Instances for Activation | SAP Help Portal</A>&nbsp;but I am not sure where I should call below Activate logic so it can activate the draft instances and it can be moved to Persistent Table.&nbsp;&nbsp;</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Shahab2_0-1721232221609.png" style="width: 400px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/137808i549A43E3EB2310A8/image-size/medium?v=v2&amp;px=400" role="button" title="Shahab2_0-1721232221609.png" alt="Shahab2_0-1721232221609.png" /></span></P><P>Below is the Business definition logic placed.</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Shahab2_2-1721232097619.png" style="width: 400px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/137807iAACCC158956EE6C4/image-size/medium?v=v2&amp;px=400" role="button" title="Shahab2_2-1721232097619.png" alt="Shahab2_2-1721232097619.png" /></span></P><P>Please guide me how It can be achieved.&nbsp;</P><P>Br,</P> 2024-07-17T18:03:52.797000+02:00 https://community.sap.com/t5/technology-q-a/how-to-hidden-parameter-element-with-abap-public-cloud/qaq-p/13764538 How to hidden parameter element with ABAP public cloud? 2024-07-18T11:42:47.595000+02:00 Phuhs https://community.sap.com/t5/user/viewprofilepage/user-id/1483297 <P>Hi experts,</P><P>I want to hide parameters with conditions.</P><P>&nbsp;</P><P>You can see the attachment image below :<span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Parameter Data Defination" style="width: 999px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/138275iCC2C2E2C564E9D72/image-size/large?v=v2&amp;px=999" role="button" title="img_parameters.png" alt="Parameter Data Defination" /><span class="lia-inline-image-caption" onclick="event.preventDefault();">Parameter Data Defination</span></span></P><P><SPAN><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Behavior Defination" style="width: 999px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/138277iD68033DC38432796/image-size/large?v=v2&amp;px=999" role="button" title="img_behaviorDefinitions.png" alt="Behavior Defination" /><span class="lia-inline-image-caption" onclick="event.preventDefault();">Behavior Defination</span></span></SPAN></P><P>Example: hide parameter element Company (P_Company) when ReportID equals 'API1' or 'TB'.</P><P><SPAN><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Web app" style="width: 999px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/138276iF8C7D4512D17EBFD/image-size/large?v=v2&amp;px=999" role="button" title="img_web_parameter.png" alt="Web app" /><span class="lia-inline-image-caption" onclick="event.preventDefault();">Web app</span></span>Please help me. Thanks&nbsp;<SPAN>and best&nbsp;</SPAN>Regards</SPAN></P><P>Daroi</P> 2024-07-18T11:42:47.595000+02:00 https://community.sap.com/t5/technology-q-a/issue-with-storing-action-parameter-data-in-draft-table-on-non-editable/qaq-p/13764617 Issue with Storing Action/Parameter Data in Draft Table on Non-Editable Object Page 2024-07-18T12:50:15.477000+02:00 ankahit https://community.sap.com/t5/user/viewprofilepage/user-id/1464269 <P>Hey Experts,</P><P>I have a situation where I have one action button with a parameter. Currently, this parameter or action occurs before the edit action. The issue I'm facing is that since my object page is non-editable, the data from that pop-up is not getting stored in the draft table. I have already implemented draft logic, but it isn't functioning as expected. Does anyone have any ideas on how I can store the data in the draft table even though my object page is not editable? or is there any alternate to store parameter value some where so I can save data on Update other than creating a table?</P><P>Your expertise and advice would be greatly appreciated.</P><P>Thank you for your assistance.</P> 2024-07-18T12:50:15.477000+02:00 https://community.sap.com/t5/technology-q-a/show-result-of-custom-action-in-popup-window/qaq-p/13764628 Show result of custom action in popup window 2024-07-18T12:56:43.445000+02:00 Kostiantyn_K https://community.sap.com/t5/user/viewprofilepage/user-id/143342 <P>Hello, experts</P><P>Didn't find solution for subject.</P><P>My question is is it possible to create custom action in behavior of entity which collects the data and show it in popup window?</P><P>My task is collect data for keys which entity contains and show that data in popup screen.</P><P>Thank you for any suggestion in advance.</P> 2024-07-18T12:56:43.445000+02:00 https://community.sap.com/t5/technology-q-a/rap-directly-navigate-to-list-or-next-position-after-saving-objectpage/qaq-p/13767782 RAP directly navigate to List or next position after saving Objectpage 2024-07-22T14:14:12.873000+02:00 itp_mka https://community.sap.com/t5/user/viewprofilepage/user-id/723083 <P><SPAN><SPAN class="">Hello guys/experts,</SPAN></SPAN></P><P><SPAN><SPAN class="">I'm developing a RAP application and have the following &nbsp;requirement. When I selected one entry from the list, went to details, changed and saved them, I need to go to the detail view of next entry from the result list without clicking on back button and returning to the original result list or if there is no next entry i need to automatically return to the list overview. </SPAN></SPAN></P><P><SPAN><SPAN class="">Is it possible?</SPAN></SPAN></P><P><SPAN><SPAN class="">My search in &nbsp;the dev forum braught unfortunately no results .</SPAN></SPAN></P> 2024-07-22T14:14:12.873000+02:00 https://community.sap.com/t5/technology-q-a/sap-rap-restful-abap-standard-table-with-draft-table-problem/qaq-p/13769259 SAP RAP(Restful ABAP) Standard Table With Draft Table Problem 2024-07-23T15:11:11.828000+02:00 woongkipark https://community.sap.com/t5/user/viewprofilepage/user-id/151870 <P>We are creating an app that SAP RAP and exclusive locks with DRAFT functions.</P><P>In general, greenfield implementation using CBO is not a big problem</P><P>&nbsp;</P><P>One question arose during the implementation of Brownfield using Standard Objects.</P><P>&nbsp;</P><P>CRUD of the Standard Table with BAPI etc through the Unmanaged implementation seems possible, but... what should I do with the lock mechanism?</P><P>&nbsp;</P><P>I understand that RAP should use DRAFT table based on Durablelock because odata Rest API is stateless.</P><P>&nbsp;</P><P>To Use this DRAFT feature, I understand that the LAST_CHANGED_AT field needs to be added to the model entity</P><P>&nbsp;</P><P>At this time, I realized that the standard table does not have the last_changed_AT field.</P><P>&nbsp;</P><P>For example, when we use that EKKO EKPO app with a scenario to update through BAPI. It is possible to implement without considering the draft function, but if i want to use the draft function, it seems impossible to implement without adding LAST CHANGED AT to the standard table</P><P>&nbsp;</P><P>Am I making a mistake? I'm sure there's a way, but I'm not sure. Please help me, everyone</P><P>&nbsp;</P><P>#RAP <a href="https://community.sap.com/t5/c-khhcw49343/ABAP+RESTful+Application+Programming+Model/pd-p/7e44126e-7b27-471d-a379-df205a12b1ff" class="lia-product-mention" data-product="909-1">ABAP RESTful Application Programming Model</a>&nbsp;</P> 2024-07-23T15:11:11.828000+02:00 https://community.sap.com/t5/technology-q-a/is-it-possible-to-do-validation-in-unmanaged-rap-without-a-draft/qaq-p/13769551 Is it possible to do validation in unmanaged RAP without a draft? 2024-07-23T20:47:53.743000+02:00 PamarthiChandana https://community.sap.com/t5/user/viewprofilepage/user-id/1470418 <P>When I try to create the entry, I get No data found for OData V2 service binding. I got the below error. When I checked the metadata for the service generated, it had the ‘IsActiveEntity’ key field.</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="PamarthiChandana_5-1721760032046.jpeg" style="width: 400px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/140740i39DD3D33CD236800/image-size/medium?v=v2&amp;px=400" role="button" title="PamarthiChandana_5-1721760032046.jpeg" alt="PamarthiChandana_5-1721760032046.jpeg" /></span></P><P>&nbsp;</P><P>&nbsp;</P><DIV class="">&nbsp;</DIV><P>&nbsp;</P><P>&nbsp;</P> 2024-07-23T20:47:53.743000+02:00 https://community.sap.com/t5/technology-q-a/rap-framework-custom-entities-get-expanded-entityset/qaq-p/13769746 RAP Framework - Custom Entities GET_EXPANDED_ENTITYSET 2024-07-24T05:49:48.549000+02:00 nicmon https://community.sap.com/t5/user/viewprofilepage/user-id/1453413 <P>Hello Experts!</P><P>We have an scenario where we need to migrate a SEGW service to RAP. This service retrieves values from custom tables but has several entities and a lot of custom logic behind, so we opted for custom entities.</P><P>The problem is that in the current SEGW we are using the&nbsp;<SPAN>GET_EXPANDED_ENTITYSET functionality and we are not being able to replicate that with Custom Entities.</SPAN></P><P><SPAN>When reading the different entities data we need to be able to access the previous ones. For example: we read the Header custom entity but then the system process the read of the Positions custom entity in a different session so we can't access the Header data even if we try to do it with memory or global variables.</SPAN></P><P><SPAN>The return of the service works fine, the EXPAND is working and we end up getting the Header and the Position entities together, but the problem is that when reading the Positions we need to do some custom logic that involves using the Header data we can't access.</SPAN></P><P><SPAN>Is it possible to achieve this? Or is there a workaround to handle GET_EXPANDED_ENTITYSET while using custom entities?</SPAN></P><P><SPAN>Thanks and regards!</SPAN></P> 2024-07-24T05:49:48.549000+02:00 https://community.sap.com/t5/technology-q-a/rap-restfulabap-custom-entity-projection-view-problems/qaq-p/13769752 RAP(RestfulABAP) custom entity Projection view Problems 2024-07-24T06:05:18.841000+02:00 woongkipark https://community.sap.com/t5/user/viewprofilepage/user-id/151870 <P><SPAN>Hello</SPAN><BR /><BR /><SPAN>I am currently publishing an OData API that queries data through RAP Managed Query.</SPAN><BR /><BR /><SPAN>It was working well, but customer requirements added a business scenario in which data was added to a specific CBO table when certain privileged users READ data.</SPAN><BR /><BR /><SPAN>After reviewing the lifecycles of the RAP to use the feature, we conclude that MANAGED QUERY does not have any special events to deal with it.</SPAN><BR /><BR /><SPAN>So I'm trying to change the existing query to UNMANAGED Query to implement this, but there was a problem.</SPAN><BR /><BR /><SPAN>Currently, our BO is not directly bound to the service, but binding through the projection view.</SPAN><BR /><BR /><SPAN>Problem is I'm trying to replace Root Entities with Custom Entities, so Custom Entities do not allow projection views!!</SPAN><BR /><BR /><SPAN>Because projection views are not allowed, deleting entire projection structures and changing them to use custom entities directly will require a huge number of code changes and likely have negative side effects.</SPAN><BR /><BR /><SPAN>So.. is there another way to projection this custom entity through "AS Projection On [custom entity]" &lt; grammar?</SPAN><BR /><BR /><SPAN>Or, is there a separate callback that allows me to perform my custom logic after a read event occurs to use managed queries as they are?</SPAN><BR /><BR /><SPAN>Best regards</SPAN><BR /><BR /><a href="https://community.sap.com/t5/c-khhcw49343/ABAP+RESTful+Application+Programming+Model/pd-p/7e44126e-7b27-471d-a379-df205a12b1ff" class="lia-product-mention" data-product="909-1">ABAP RESTful Application Programming Model</a>&nbsp;<BR />@</P> 2024-07-24T06:05:18.841000+02:00 https://community.sap.com/t5/technology-q-a/design-of-the-behavior-handler-abap-restful-programming-model-rap-managed/qaq-p/13770154 Design of the behavior handler - ABAP RESTful Programming Model (RAP) - Managed scenario 2024-07-24T11:43:54.875000+02:00 Matteo_Serina https://community.sap.com/t5/user/viewprofilepage/user-id/13880 <P>Hi experts,</P><P>I recently read the blog-post “<A href="https://community.sap.com/t5/technology-blogs-by-members/abap-oo-design-applied-to-abap-restful-programming-model-rap-unmanaged/ba-p/13539008" target="_blank"><STRONG>ABAP OO Design applied to ABAP RESTful Programming model (RAP) - Unmanaged scenario</STRONG></A>” from <a href="https://community.sap.com/t5/user/viewprofilepage/user-id/164553">@AlwinPut</a>&nbsp;and I wonder if similar OO design concepts can be applied to the managed scenario.</P><P>A real world application can easily grow up introducing several features that extend the BO behavior.<BR />In this case the local class implementing the behavior handler becomes huge quickly, therefore it would be hardly maintainable.</P><P>It would be great to apply SRP and SoC principles developing each feature in a separate class; each determination, validation or action logic would be developed in its own class, while the behavior handler local class would act as a façade.</P><P>Adopting this approach even a complex app would be developed leveraging on simple short classes that would be easier to maintain (even by different developers within a team).</P><P>Do you have any suggestions to easily setup this architecture (handling the derived data types in a smart way too)?</P><P>Do you notice any drawback to point out related to this approach?</P> 2024-07-24T11:43:54.875000+02:00 https://community.sap.com/t5/technology-q-a/how-to-pass-error-message-from-read-method-in-behavior-implementation-class/qaq-p/13770290 How to pass error message from read method in behavior implementation class? 2024-07-24T14:08:51.309000+02:00 amit5ingh https://community.sap.com/t5/user/viewprofilepage/user-id/11198 <P>Hi Experts,<BR /><BR />We have a requirement where we need to pass error messages if the data extracted from the CDS view belongs to a certain Sales Organization.<BR />The development is done using RAP framework, data is being extracted from standard tables in interface CDS views which are being used in final consumption view. The application is display only and the whole thing works fine.<BR />But now we have a requirement where we need to show error message instead of data if certain result set is extracted. So can we use read method of behavior implementation class, where we can check the result set and pass the data or error message accordingly?</P> 2024-07-24T14:08:51.309000+02:00 https://community.sap.com/t5/technology-q-a/rap-unmanaged-query-with-managed-bo-problems/qaq-p/13770537 RAP Unmanaged Query with MANAGED BO Problems 2024-07-24T16:51:41.700000+02:00 woongkipark https://community.sap.com/t5/user/viewprofilepage/user-id/151870 <P>I created a custom logic using UNAMANGED QUERY in SAP RAP.</P><P>Subsequently, with a MANAGED with unmanaged save scenario for the corresponding Custom Entities, we created a BDEF that implements an extension to storage logic.</P><P>The problem occurred when we did Entitiy CREATE for that BO.</P><P>When I try to create Entitiy, I get ABAP Dump strangely.</P><P>When I checked that dump, logic to query the dynamic openSQL SELECT for Custom Entities In Standard Source.</P><P>I don't know why, even though I use Custom Entities, I run them to do a query with that entity name.</P><P>A custom entity is just an entity name... and there is a separate table to perform my true CRUD..</P><P>( For example, a custom entity named "Z_I_CUSTOMENTITY" exists,<BR />If the actual CRUD is done in a table called "ZT_CUSTOM" via SAVE_MODIFIED.. )</P><P>The current behavior of the default BO is that it recognizes Z_I_CUSTOMENTITY as a table and performs a dynamic query to query the data..</P><P>Can't we use UNMANAGED Query and Managed scenarios together in the first place?<BR /><BR />-- Dump debug</P><P><span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="woongkipark_0-1721833223667.png" style="width: 706px;"><img src="https://community.sap.com/t5/image/serverpage/image-id/141100i0699291D4B4F5D7A/image-dimensions/706x284?v=v2" width="706" height="284" role="button" title="woongkipark_0-1721833223667.png" alt="woongkipark_0-1721833223667.png" /></span></P><P>&nbsp;</P><P><BR /><BR /><a href="https://community.sap.com/t5/c-khhcw49343/ABAP+RESTful+Application+Programming+Model/pd-p/7e44126e-7b27-471d-a379-df205a12b1ff" class="lia-product-mention" data-product="909-1">ABAP RESTful Application Programming Model</a>&nbsp;</P> 2024-07-24T16:51:41.700000+02:00 https://community.sap.com/t5/technology-q-a/data-validation-in-rap-web-service-with-messages-in-response/qaq-p/13770657 Data Validation in RAP web service with messages in response 2024-07-24T18:00:06.465000+02:00 BhargavJack https://community.sap.com/t5/user/viewprofilepage/user-id/1487784 <P>Hi All,</P><P>I Have one scenario whare i have to validate some data using rap in odata web service.&nbsp;</P><P>The data are coming in specific payload. I have to validate this data and if any error message is coming i have to send as response. This one is web Odata so i can not send messages as an error message. The all functionality i have to do in GET method only.</P><P>Any way to do this one?</P><P>sample payload</P><P><!-- StartFragment --><SPAN>{<BR />&nbsp;&nbsp;<SPAN class="">"company_code"&nbsp;</SPAN>:&nbsp;<SPAN class="">"3N6R"</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"profit_center"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"trading_partner"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"gl_account"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"cost_center"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"internal_order"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"wbs_elements"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"Customer"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"Vendor"&nbsp;</SPAN>:&nbsp;<SPAN class="">""</SPAN>,<BR />&nbsp;&nbsp;<SPAN class="">"posting_date"&nbsp;</SPAN>:&nbsp;<SPAN class="">"\/Date(1721088000000)\/"</SPAN><BR />}</SPAN></P> 2024-07-24T18:00:06.465000+02:00