PLSQL in different schema without global synonyms
cavadino2 opened this issue · 5 comments
Hi,
I installed utPLSQL in a seperate schema, without global synonyms.
So I did not ran the script source/create_synonyms_and_grants_for_public.sql
but I ran the script source/create_user_grants.sql
This works all fine in database. I have my user hr, which has some tests and ut3, where utPLSQL is installed. I can execute all my tests as hr user in the DB by calling
exec ut3.ut.run;
But I cannot use the CLI. When I connect with the hr User, I get
utPLSQL framework is not installed on your database or not accessable to the user you are connected with
Using the ut3 User with CLI works in general technically, but he does not have any read permissions to hr. So he does not find any test.
I would expect and recommend to have an optional parameter like -UTSchema where I can pass the schema, where utPLSQL is installed. So I could connect like
utplsql run hr/hr@myDB -UTSchema ut3
Happy to hear your comments,
Sebastian
This is intersting issue.
I would expect cli to work just fine.
It seems that the check for ut3 existence is not working correctly.
Can youalso execute tests from HR schema by calling: ut.run
without UT3?
You need yo create private synonyms in HR schema for UT3.
There are scripts provided to create synonyms as well as grants for schema:
https://github.com/utPLSQL/utPLSQL/blob/develop/source/create_user_grants.sql
https://github.com/utPLSQL/utPLSQL/blob/develop/source/create_user_synonyms.sql
Grants shpuld be executed as UT3
Synonyms as HR.
With that you should be all set.
Let us know if that doesn't help.
You are right. I missed to execute create_user_synonyms.sql.
After executing it, the CLI works just fine.
Thank you very much