User 10a23c54c1
21-09-2005 06:34:24
I have the same problem I have reported earlier by email while trying to use JChem indexes by multiple Oracle users.
In my case the JChem objects are owned by the schema 'JCHEM_CARTRIDGE' with DBA privileges. I also have a 'user' schema say 'JCHEM_USER' with normal privileges and it has a role with permissions generated by the SQL query
select 'grant execute on ' || a.OBJECT_NAME || ' to JCHEM;' from all_objects a where a.OWNER= 'JCHEM_CARTRIDGE' and a.OBJECT_TYPE in ('PACKAGE', 'FUNCTION', 'OPERATOR', 'TYPE', 'INDEXTYPE', 'PROCEDURE', 'PACKAGE BODY', 'TYPE BODY') union all select 'grant select on ' || a.OBJECT_NAME || ' to JCHEM;' from all_objects a where a.OWNER = 'JCHEM_CARTRIDGE' and a.OBJECT_TYPE in ('SEQUENCE', 'TABLE');
as you have recommended. Now when I index a table in JCHEM_CARTRIDGE and index it as JCHEM_CARTRIDGE, 'JCHEM_USER' is able to use it without any problems. However, it doesn't work if I try the opposite; when I create and index a table with JCHEM_USER and then try a structural search as JCHEM_CARTRIDGE here is what I get
*
ERROR at line 1:
ORA-29925: cannot execute JCHEM_CARTRIDGE.JC_IDXTYPE_IM.ODCIINDEXSTART
ORA-00904: : invalid identifier
while JCHEM_USER is able to use the index. It seems that JCHEM_USER has all the permissions and JCHEM_CARTRIDGE is DBA so it has access to all the tables. Can you please help me to figure out what is wrong with my setup?
Thanks
Hayk
GNF
In my case the JChem objects are owned by the schema 'JCHEM_CARTRIDGE' with DBA privileges. I also have a 'user' schema say 'JCHEM_USER' with normal privileges and it has a role with permissions generated by the SQL query
select 'grant execute on ' || a.OBJECT_NAME || ' to JCHEM;' from all_objects a where a.OWNER= 'JCHEM_CARTRIDGE' and a.OBJECT_TYPE in ('PACKAGE', 'FUNCTION', 'OPERATOR', 'TYPE', 'INDEXTYPE', 'PROCEDURE', 'PACKAGE BODY', 'TYPE BODY') union all select 'grant select on ' || a.OBJECT_NAME || ' to JCHEM;' from all_objects a where a.OWNER = 'JCHEM_CARTRIDGE' and a.OBJECT_TYPE in ('SEQUENCE', 'TABLE');
as you have recommended. Now when I index a table in JCHEM_CARTRIDGE and index it as JCHEM_CARTRIDGE, 'JCHEM_USER' is able to use it without any problems. However, it doesn't work if I try the opposite; when I create and index a table with JCHEM_USER and then try a structural search as JCHEM_CARTRIDGE here is what I get
*
ERROR at line 1:
ORA-29925: cannot execute JCHEM_CARTRIDGE.JC_IDXTYPE_IM.ODCIINDEXSTART
ORA-00904: : invalid identifier
while JCHEM_USER is able to use the index. It seems that JCHEM_USER has all the permissions and JCHEM_CARTRIDGE is DBA so it has access to all the tables. Can you please help me to figure out what is wrong with my setup?
Thanks
Hayk
GNF