<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Create Modify or delete role objects using BApi in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13885585#M4886495</link>
    <description>I'm not surprised, it was GenAI Assisted Content.</description>
    <pubDate>Wed, 02 Oct 2024 12:27:23 GMT</pubDate>
    <dc:creator>Sandra_Rossi</dc:creator>
    <dc:date>2024-10-02T12:27:23Z</dc:date>
    <item>
      <title>Create Modify or delete role objects using BApi</title>
      <link>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaq-p/13884141</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I need to know if there is any way to modify create or add objects to roles. I am seeing that the only standard thing is to use the /GRCPI/GRIA_MASS_UPD_ROLE function , I also use other functions to achieve my purpose such as PRGN_AUTO_GENERATE_PROFILE_NEW and i use the RFC_READ_TABLE function to read from the AGR_DEFINE table and there if a role is a parent or child. At the end I commit the changes with the bapi. But I can't get it to change or add any object to the role.&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;</description>
      <pubDate>Tue, 01 Oct 2024 08:56:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaq-p/13884141</guid>
      <dc:creator>caristeo</dc:creator>
      <dc:date>2024-10-01T08:56:10Z</dc:date>
    </item>
    <item>
      <title>Re: Create Modify or delete role objects using BApi</title>
      <link>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13884216#M4886278</link>
      <description>&lt;P&gt;What are those "objects"? &lt;A href="https://me.sap.com/notes/2465316/E" target="_blank"&gt;2465316 - Role menu API: Base class CL_PFCG_MENU_MODIFY - SAP for Me&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Oct 2024 09:27:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13884216#M4886278</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2024-10-01T09:27:55Z</dc:date>
    </item>
    <item>
      <title>Re: Create Modify or delete role objects using BApi</title>
      <link>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13884884#M4886390</link>
      <description>&lt;P&gt;To add or change objects in roles within an SAP system, there are specific steps and functions you can use beyond those you’ve already mentioned. Here’s a possible approach:&lt;/P&gt;
&lt;P&gt;Use Transaction PFCG: In transaction PFCG, you can manually modify roles and add or remove objects. If you want to automate this process, various BAPIs and function modules come into play.&lt;/P&gt;
&lt;P&gt;Function Modules for Changing Authorizations: PRGN_1252_AUTH_ADD: This function module adds authorization objects to a role. PRGN_1252_AUTH_CHANGE: This allows you to modify the authorizations of a role. This is helpful for changing existing authorizations or adding new ones.&lt;/P&gt;
&lt;P&gt;Use BAPIs to Update the Role:&lt;/P&gt;
&lt;P&gt;BAPI_ROLE_SAVE: This BAPI is used to save a role after editing, similar to using transaction PFCG. BAPI_ROLE_ACTGROUP_ASSIGN: This allows you to assign authorizations to a role. Checking and Reading Authorization Objects:&lt;/P&gt;
&lt;P&gt;Use function modules like RFC_READ_TABLE to read information about authorization objects from tables like AGR_1251 (role authorizations) and AGR_DEFINE (role definition), just as you are already doing.&lt;/P&gt;
&lt;P&gt;Mass Changes with /GRCPI/GRIA_MASS_UPD_ROLE: The function /GRCPI/GRIA_MASS_UPD_ROLE, which you mentioned, is also useful for making mass changes to roles, but for specifically changing an authorization object in a role, BAPIs are often the better choice.&lt;/P&gt;
&lt;P&gt;Commit the Changes: After you’ve added or modified the objects, you need to ensure that you properly the changes. You can do this by using BAPI_TRANSACTION_COMMIT after the role modification or saving.&lt;/P&gt;
&lt;P&gt;If you cannot change a specific role or authorization object, the following might be relevant: Missing Authorizations: Check if you have the necessary permissions to modify roles. Object Anchored in Another Role: Sometimes, objects are set in higher-level or derived roles. This could explain why your changes aren’t taking effect.&lt;/P&gt;
&lt;P&gt;If you have more details about a specific error or scenario, I can provide more targeted assistance.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;** ADDED BY MODERATION** GenAI Assisted Content&lt;/P&gt;</description>
      <pubDate>Wed, 02 Oct 2024 07:56:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13884884#M4886390</guid>
      <dc:creator>Fullstack_Dev</dc:creator>
      <dc:date>2024-10-02T07:56:19Z</dc:date>
    </item>
    <item>
      <title>Re: Create Modify or delete role objects using BApi</title>
      <link>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13885567#M4886494</link>
      <description>&lt;P&gt;I tried to find&amp;nbsp;&lt;SPAN&gt;PRGN_1252_AUTH_ADD or something related functions PRGN_1252_AUTH_CHANGE and not exist. And&amp;nbsp;BAPI_ROLE_ACTGROUP_ASSIGN is just for user assign role, and&amp;nbsp;BAPI_ROLE_SAVE not exist, and i want to use Bapi remotely.. If there is any existing in sap or what bapi do I need to develop to get it.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 Oct 2024 12:15:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13885567#M4886494</guid>
      <dc:creator>caristeo</dc:creator>
      <dc:date>2024-10-02T12:15:02Z</dc:date>
    </item>
    <item>
      <title>Re: Create Modify or delete role objects using BApi</title>
      <link>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13885585#M4886495</link>
      <description>I'm not surprised, it was GenAI Assisted Content.</description>
      <pubDate>Wed, 02 Oct 2024 12:27:23 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/create-modify-or-delete-role-objects-using-bapi/qaa-p/13885585#M4886495</guid>
      <dc:creator>Sandra_Rossi</dc:creator>
      <dc:date>2024-10-02T12:27:23Z</dc:date>
    </item>
  </channel>
</rss>

