Closed S-Hahne closed 9 months ago
@S-Hahne Thanks for the version information. What operations are you doing when the error occurs?
Hi @isc-bsaviano,
this just happens when opening a class definition from one of our namespaces.
Sorry, forgot to mention that in the issue description.
The most important query to have permission on is StudioOpenDialog, but that's not new for this version. Are you using server-side editing or client-side editing? Also, Ii you upgrade to IRIS 2021.1.3+, 2022.1.1+ or 2022.2+ you shouldn't get SQL permissions errors due to a server-side bug fix.
The permission on StudioOpenDialog is for sure granted. We've done that years ago and this issue just arises from the 0-beta.7 to 0-beta.8 and is gone if I roll back. So the answer to our issue must be somewhere in here.
I think I found the issue: In line 293 of src/commands/unitTest.ts "SELECT Name||'.cls' FROM %Dictionary.ClassDefinition_SubclassOf('%UnitTest.TestCase','@')"
As soon as I grant EXECUTE on this SQL procedure in the namespace, the error message vanishes.
Does this sound reasonable? And is this privilege included in the newer IRIS versions you mentioned?
@S-Hahne What version of IRIS are you connected to? Yes, that query was added but I'm not sure why it's being run if you have a server version old enough to report these permissions errors. That unit test code should only be run if your server is 2023.3 or newer. If it's running for all servers then there's a bug that I need to fix.
It's IRIS for Windows (x86-64) 2020.1.4 (Build 536U)
I have removed the privilege again from our %Developer role. Let me know once you have a fixed version for me to test :)
@S-Hahne Can you please download and install the vsix found here? This should fix your issue.
Hi Brett,
yes, it does. No more SQLCODE -99 messages when I open a class. Many thanks. Should I close the Issue here or will you do that?
Please let me know the version number (2.12.1-beta-which?) of the fix once that is published. Then I'll be able to spread the word to my fellow colleagues.
Best regards, Sebastian
Thanks for testing! I'm glad the fix worked. This issue will close automatically when the pull request is merged. The version will almost certainly be 2.12.1-beta.2
@S-Hahne 2.12.1-beta.2 has been built and can be found here
Dear team,
I was just made aware that we're getting the following messages from the ObjectScript extension since the automatic update to 1.12.0 today:
ERROR #5540: SQLCODE: -99 Message: User <username hidden> is not privileged for the operation
I tracked this behaviour to have changed between 2.12.0-beta.7 and -beta.8 Hopefully the changes are small enough to track the issue without much effort.
Does anyone know the SQL privileges that are now required to work with the extension? Our server is locked down, so we will most likely need to add some rights to the %Developer role again.
Best regards, Sebastian