cancel
Showing results for 
Search instead for 
Did you mean: 

SAP DBTech JDBC: [258]: insufficient privilege: Not authorized - SAP HANA

Former Member
0 Kudos

Dear All,

We are getting the below error when we tried to call procedure ART_PROC using the SYSTEM user in SAP HANA Studio,

Could not execute 'call "TESTECC"."ART_PROC"'

SAP DBTech JDBC: [258]: insufficient privilege: Not authorized

Kindly provide your suggestions on the same.

Thanks

Arun R

Accepted Solutions (1)

Accepted Solutions (1)

aadityanigam
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Arun,

Firstly it is **not** recommended to use SYSTEM for anything other than management tasks.

My Assumptions

* the procedure ART_PROC was not created by the SYSTEM user

Solution : you need to give EXECUTE privileges on the procedure to SYSTEM

How: Only the user who created the procedure or who has been give grant privilege can give the EXECUTE privilege. SYSTEM cannot give itself this privilege

For the Grant command check out sec 1.8.6.17 of the http://help.sap.com/hana/SAP_HANA_SQL_Script_Reference_en.pdf

OR

in the HANA Studio

in the System tab expand the system with the log in user as the owner/grantor of the privilege

here you will see a node called Security.

Right-click and choose 'Find User/Role'

Type System in the search dialog that opens - double click on SYSTEM user displayed below

System user opens up - Navigate to Object Privileges tab

here using the green '+' button  search for ART_PROC and then on the right side tick the 'Execute' checkbox

click on save.

Warm regards

aadi

Former Member
0 Kudos

Hi Nigam,

Thanks for the response.

I have tried the same, but getting the below error.

Could not modify user. Could not grant privilege 'EXECUTE' on 'ART_PROC (TESTECC)'. You are not authorized to perform the required actions.

Thanks

Arun R

aadityanigam
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Arun,

Please identify the owner of the procedure ART_PROC.

Also are you working on the trial landscape?

see if you can execute this query


select * from OWNERSHIP

where object_name like '%ART_PROC%'

this will give you the owner name and you need to log in as that owner to grant privilege

(or find a user who had Grant privilege on the object - we will come to that later)

Warm regards

aadi

Former Member
0 Kudos

Hi Aadi,

This is a Dev environment.

I have logged in with the owner (KARAN) of the procedure and I have tried to grant execute to SYSTEM user.

But still no luck.

SCHEMA_NAME;   OWNER_NAME;   OBJECT_NAME;   OBJECT_TYPE;         OBJECT_OID

TESTECC;             KARAN;                ART_PROC;         PROCEDURE;           312,323

Getting Error: Could not modify user 'SYSTEM'. Could not grant privilege 'EXECUTE' on 'ART_PROC (TESTECC)'. You are not authorized to perform the required actions

Thanks

Arun R

aadityanigam
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello Arun,

I am bit stumped too...

I will try and dig around to see what the issue is...

Warm regards

aadi

former_member182302
Active Contributor
0 Kudos

Hi Arun,

I did face these issues some times.

It is like the tables or views you are using in the procedure code, some of those objects might not be accessible from the user which is trying to call the procedure.

2 things you can do here to check what is missing:

1) "Show Authorization" option. You can right click on the procedure and click on it. It will show you a detailed diagram of what is missing.

2) If the above option doesn't work you can use authorization relevant traces to see what is missing.

Regards,

Krishna Tangudu

Former Member
0 Kudos

Thanks Krishna, we have followed the same yesterday and were able to provide access.

Answers (0)