Online Tutorials & Training Materials | STechies.com
Register Login

Fix for getting current user from a stored procedure in SAP HANA DB.

04 Oct 2012 5:16 pm || 0

Due to a programming error in SAP HANA DB Revsion 25 and previous, the function "CURRENT_USER" of a SQLScript procedure in definer mode returned the calling user

Update to SAP HANA Revision 26 or later

Note:
If you run a Revision of SAP HANA SP03 you have the possibility to switch to the behaviour of SAP HANA db Revision 25 or previous.
The switch can be done by setting in Revision 26 or later in HDBIndexserver.ini:
           [sqlscript]

           use_old_current_user_semantic = true


The HDBIndexserver needs to be restarted to activate the setting