Objects count not matched in apps and readonly user in EBS(19c database)
We created readonly user(appsread) in database 19c. We granted the permissions from apps to appsread but objects count is not matched.
we used folowing two scripts,
SCRIPT 1:
SET ECHO OFF
SET PAGESIZE 0
SET LINESIZE 300
-- 1. Generate script to create synonyms
SPOOL create_synonyms.sql
SELECT 'CREATE SYNONYM ' || OBJECT_NAME || ' FOR ' || OWNER || '.' || OBJECT_NAME || ';'
FROM ALL_OBJECTS
WHERE OWNER IN ('APPS')
AND OBJECT_NAME NOT LIKE '%/%'
AND OBJECT_TYPE IN ('TABLE', 'VIEW', 'SYNONYM');
SPOOL OFF;
-- 2. Generate script to grant select privileges
SPOOL grant_select.sql
SELECT 'GRANT SELECT ON ' || OWNER || '.' || OBJECT_NAME || ' TO APPSREAD;'