日期:2014-05-17 浏览次数:21180 次
CREATE SYNONYM F FOR B.X
BEGIN
FOR i IN (SELECT object_name
FROM all_objects s
WHERE s.object_type = 'FUNCTION'
AND s.owner = 'B'
AND NOT EXISTS (SELECT 1 FROM all_synonyms t WHERE t.synonym_name = s.object_name))
LOOP
EXECUTE IMMEDIATE 'CREATE SYNONYM '
------解决方案--------------------
i.object_name
------解决方案--------------------
' FOR B.'
------解决方案--------------------
i.object_name;
END LOOP;
END;