Skip to Content
0
Aug 04, 2023 at 02:43 AM

SAP XSA Analytical privilege and CV issue with Grant assingment to DB user

88 Views

Hi,

Can you please help me to fix the insufficient privilege to call the procedure GRANT_CONTAINER_SCHEMA_ROLES?

I've successfully created a cross-container SFLIGHT_PROJ with a dimension cv using SFLIGHT schema from XSC. I can view the data in WebIDE without analytical privilege. Then I created an Analytical privilege and a role in WebIDE and successfully built the container.

The role contains the following code:

{

"role": {

"name": "ANALYTICAL_PRIVILEGES_TO_USER",

"schema_privileges": [

{

"privileges": [ "SELECT" ]

}

],

"schema_analytic_privileges": [

{

"privileges": [ "AP_SFLIGHT" ]

}

]

}

}

Successfully built the container.

Now, I'm trying to assign the role to db user using the following command:

In the DB explorer, connected to SYSTEM(hxehost) system and in SQL editor entered the following commands.

SET SCHEMA "SFLIGHT_1#DI";

CREATE LOCAL TEMPORARY COLUMN TABLE "#ROLES" LIKE "_SYS_DI"."TT_SCHEMA_ROLES";

INSERT INTO "#ROLES"("ROLE_NAME","PRINCIPAL_SCHEMA_NAME","PRINCIPAL_NAME") VALUES

( 'ANALYTICAL_PRIVILEGES_TO_USER','','WDSOUZA');

CALL "SFLIGHT_1#DI"."GRANT_CONTAINER_SCHEMA_ROLES"

("#ROLES","_SYS_DI"."T_NO_PARAMETERS",?,?,?);

DROP TABLE "#ROLES";

The first 3 commands ran successfully. The call procedure failed with insufficient privilege.

Could not execute 'CALL "SFLIGHT_1#DI"."GRANT_CONTAINER_SCHEMA_ROLES"( "#ROLES", "_SYS_DI"."T_NO_PARAMETERS", ?, ?, ? ...'

Error: (dberror) [258]: insufficient privilege: Detailed info for this error can be found with guid 'C7D9B03B7360FD4E8FB2B93675F6D918'

The following procedure produces the results as under

CALL "SYS"."GET_INSUFFICIENT_PRIVILEGE_ERROR_DETAILS"( 'C7D9B03B7360FD4E8FB2B93675F6D918', ? );

session and checked user name : SYSTEM

privilege : EXECUTE

Is Missing Analytical and Grant (both) : FALSE

Schema name SFLIGHT_1#DI

Procedure : GRANT_CONTAINER_SCHEMA_ROLES